Skip to content

Commit

Permalink
Fix realms reconnection
Browse files Browse the repository at this point in the history
  • Loading branch information
NotRyken committed Dec 21, 2024
1 parent 4e562cf commit 61c5b62
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 1.0.3

- Fixed realms reconnection

## 1.0.2

- Fixed YACL dependency ID
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@

@Mixin(DisconnectedRealmsScreen.class)
public class MixinDisconnectedRealmsScreen extends Screen {
@Unique
private boolean autoReconnect$firstInit = true;
@Unique
private boolean autoReconnect$shouldAutoReconnect;
@Unique
Expand All @@ -67,7 +65,7 @@ private void init(CallbackInfo info) {
Button reconnectButton = buttons.getFirst();
Button cancelButton = buttons.size() == 2 ? buttons.getLast() : null;

if (!autoReconnect$firstInit && autoReconnect$shouldAutoReconnect) {
if (autoReconnect$shouldAutoReconnect) {
AutoReconnect.startCountdown(
(seconds) -> ScreenMixinUtil.countdownCallback(reconnectButton, seconds));
}
Expand All @@ -80,7 +78,6 @@ private void init(CallbackInfo info) {
reconnectButton.setMessage(localized("message", "reconnect"));
};
}
autoReconnect$firstInit = false;
}

@Unique
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Neo/Forge version ranges: https://maven.apache.org/enforcer/enforcer-rules/versionRanges.html

# Project
mod_version=1.0.2+1.21
mod_version=1.0.3+1.21
mod_group=dev.terminalmc
mod_id=autoreconnectrf
mod_name=AutoReconnect
Expand Down

0 comments on commit 61c5b62

Please sign in to comment.