fix: report button could still be interacted with

- fixes #3
This commit is contained in:
2022-10-07 13:36:18 -04:00
parent 299018c61b
commit de212d0b6d
3 changed files with 4 additions and 6 deletions

View File

@@ -26,7 +26,8 @@
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"vscjava.vscode-java-pack"
"vscjava.vscode-java-pack",
"vscjava.vscode-gradle"
]
}
},

View File

@@ -8,7 +8,7 @@ yarn_mappings=1.19.2+build.1
loader_version=0.14.8
# Mod Properties
mod_version = 1.2.0
mod_version = 1.2.1
maven_group = me.lucaslah
archives_base_name = no-report-button

View File

@@ -33,16 +33,13 @@ public abstract class GameMenuScreenMixin extends Screen {
for (ClickableWidget button : buttons) {
if (button.getMessage().getString().equals(I18n.translate("menu.playerReporting"))) {
button.setWidth(-9999);
button.active = false;
reportButton = button;
reportButtonFound = true;
}
}
if (reportButtonFound) {
//reportButton.setWidth(-9999);
//reportButton.setMessage(Text.of(""));
//reportButton.active = false;
ButtonWidget openToLanButton = this.addDrawableChild(new ButtonWidget(this.width / 2 + 4, this.height / 4 + 96 + -16, 98, 20, Text.translatable("menu.shareToLan"), (button) -> {
assert this.client != null;
this.client.setScreen(new OpenToLanScreen(this));