aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java
diff options
context:
space:
mode:
authorRoman / Linnea Gräf <roman.graef@gmail.com>2023-01-11 22:03:47 +0100
committerGitHub <noreply@github.com>2023-01-11 22:03:47 +0100
commit49c9345807ed4d13d035e27a0665e2f7c63b0c9e (patch)
tree203bb0c8645fff55439da6ec953100d3f63de8a0 /src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java
parent378c22c7cd98fba1f1bf1c2dd53f560deca29619 (diff)
downloadnotenoughupdates-49c9345807ed4d13d035e27a0665e2f7c63b0c9e.tar.gz
notenoughupdates-49c9345807ed4d13d035e27a0665e2f7c63b0c9e.tar.bz2
notenoughupdates-49c9345807ed4d13d035e27a0665e2f7c63b0c9e.zip
Optional Oneconfig support (#401)
Diffstat (limited to 'src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java19
1 files changed, 3 insertions, 16 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java b/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java
index 674e4068..129699da 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiItemCustomize.java
@@ -92,7 +92,7 @@ public class GuiItemCustomize extends GuiScreen {
((ItemArmor) stack.getItem()).getArmorMaterial() == ItemArmor.ArmorMaterial.LEATHER;
enchantGlintCustomColourAnimation.setValue(enchantGlint ? 17 : 0);
- this.enchantGlintButton = new GuiElementBoolean(0, 0, enchantGlint, (bool) -> {
+ this.enchantGlintButton = new GuiElementBoolean(0, 0, () -> enchantGlint, (bool) -> {
enchantGlint = bool;
updateData();
});
@@ -443,7 +443,7 @@ public class GuiItemCustomize extends GuiScreen {
editor = new GuiElementColour(
mouseX,
mouseY,
- customGlintColour == null ? ItemCustomizeManager.DEFAULT_GLINT_COLOR : customGlintColour,
+ () -> customGlintColour == null ? ItemCustomizeManager.DEFAULT_GLINT_COLOR : customGlintColour,
(colour) -> {
customGlintColour = colour;
updateData();
@@ -464,7 +464,7 @@ public class GuiItemCustomize extends GuiScreen {
updateData();
} else {
editor = new GuiElementColour(mouseX, mouseY,
- customLeatherColour == null ? getChromaStrFromLeatherColour() : customLeatherColour,
+ () -> customLeatherColour == null ? getChromaStrFromLeatherColour() : customLeatherColour,
(colour) -> {
customLeatherColour = colour;
updateData();
@@ -473,19 +473,6 @@ public class GuiItemCustomize extends GuiScreen {
}
}
- /*if(mouseX >= xCenter-90 && mouseX <= xCenter+90 &&
- mouseY >= belowEnchGlint+65 && mouseY <= belowEnchGlint+80) {
- if(true) {
- String userName = Minecraft.getMinecraft().thePlayer.getName();
- String serverId = "1872398172739";
- try {
- Desktop.getDesktop().browse(new URL("https://moulberry.codes/purchaseitemtag?uniqueId="+serverId+"&username="+userName).toURI());
- } catch(Exception ignored) {}
- } else {
-
- }
- }*/
-
super.mouseClicked(mouseX, mouseY, mouseButton);
}
}