diff --git a/gradle.properties b/gradle.properties index 0f4c0253..acf11432 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,9 +2,9 @@ org.gradle.jvmargs=-Xmx1G # Fabric Properties # check these on https://modmuss50.me/fabric.html - minecraft_version=1.20.1 - yarn_mappings=1.20.1+build.10 - loader_version=0.14.21 + minecraft_version=1.20.2 + yarn_mappings=1.20.2+build.1 + loader_version=0.14.22 # Mod Properties version_type=release revision=1 @@ -13,8 +13,8 @@ org.gradle.jvmargs=-Xmx1G archives_base_name=reeses_sodium_options # Dependency - sodium_version=mc1.20.1-0.5.2 + sodium_version=mc1.20.2-0.5.3 iris_version=1.5.2+1.19.4 #Fabric api - fabric_version=0.86.1+1.20.1 + fabric_version=0.89.0+1.20.2 diff --git a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/SodiumVideoOptionsScreen.java b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/SodiumVideoOptionsScreen.java index 7514fef7..a662b453 100644 --- a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/SodiumVideoOptionsScreen.java +++ b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/SodiumVideoOptionsScreen.java @@ -168,7 +168,7 @@ public BasicFrame.Builder parentBasicFrameBuilder(Dim2i parentBasicFrameDim, Dim @Override public void render(DrawContext drawContext, int mouseX, int mouseY, float delta) { - super.renderBackground(drawContext); + super.renderBackground(drawContext, mouseX, mouseY, delta); this.updateControls(); this.frame.render(drawContext, mouseX, mouseY, delta); } diff --git a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/ScrollableFrame.java b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/ScrollableFrame.java index 9a5eb0df..fc15e117 100644 --- a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/ScrollableFrame.java +++ b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/ScrollableFrame.java @@ -174,10 +174,8 @@ public boolean mouseDragged(double mouseX, double mouseY, int button, double del public boolean mouseReleased(double mouseX, double mouseY, int button) { return super.mouseReleased(mouseX, mouseY, button) || (this.canScrollHorizontal && this.horizontalScrollBar.mouseReleased(mouseX, mouseY, button)) || (this.canScrollVertical && this.verticalScrollBar.mouseReleased(mouseX, mouseY, button)); } - - @Override - public boolean mouseScrolled(double mouseX, double mouseY, double amount) { - return super.mouseScrolled(mouseX, mouseY, amount) || (this.canScrollHorizontal && this.horizontalScrollBar.mouseScrolled(mouseX, mouseY, amount)) || (this.canScrollVertical && this.verticalScrollBar.mouseScrolled(mouseX, mouseY, amount)); + public boolean mouseScrolled(double mouseX, double mouseY, double horizontalAmount, double verticalAmount) { + return super.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount) || (this.canScrollHorizontal && this.horizontalScrollBar.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount)) || (this.canScrollVertical && this.verticalScrollBar.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount)); } public static class Builder { diff --git a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/components/ScrollBarComponent.java b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/components/ScrollBarComponent.java index 11e5c2ec..09b86b63 100644 --- a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/components/ScrollBarComponent.java +++ b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/components/ScrollBarComponent.java @@ -109,10 +109,10 @@ public boolean mouseDragged(double mouseX, double mouseY, int button, double del } @Override - public boolean mouseScrolled(double mouseX, double mouseY, double amount) { + public boolean mouseScrolled(double mouseX, double mouseY, double horizontalAmount, double verticalAmount) { if (this.dim.containsCursor(mouseX, mouseY) || this.extendedScrollArea != null && this.extendedScrollArea.containsCursor(mouseX, mouseY)) { if (this.offset <= this.maxScrollBarOffset && this.offset >= 0) { - int value = (int) (this.offset - amount * SCROLL_OFFSET); + int value = (int) (this.offset - verticalAmount * SCROLL_OFFSET); // todo: horizontal separation this.setOffset(value); return true; } diff --git a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/tab/TabFrame.java b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/tab/TabFrame.java index 85ce3e11..150e4b9c 100644 --- a/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/tab/TabFrame.java +++ b/src/main/java/me/flashyreese/mods/reeses_sodium_options/client/gui/frame/tab/TabFrame.java @@ -155,8 +155,8 @@ public boolean mouseReleased(double mouseX, double mouseY, int button) { } @Override - public boolean mouseScrolled(double mouseX, double mouseY, double amount) { - return super.mouseScrolled(mouseX, mouseY, amount) || (this.tabSectionCanScroll && this.tabSectionScrollBar.mouseScrolled(mouseX, mouseY, amount)); + public boolean mouseScrolled(double mouseX, double mouseY, double horizontalAmount, double verticalAmount) { + return super.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount) || (this.tabSectionCanScroll && this.tabSectionScrollBar.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount)); } public static class Builder { diff --git a/src/main/java/me/flashyreese/mods/reeses_sodium_options/mixin/sodium/MixinSliderControlElement.java b/src/main/java/me/flashyreese/mods/reeses_sodium_options/mixin/sodium/MixinSliderControlElement.java index 0eda8b1e..f2d13caa 100644 --- a/src/main/java/me/flashyreese/mods/reeses_sodium_options/mixin/sodium/MixinSliderControlElement.java +++ b/src/main/java/me/flashyreese/mods/reeses_sodium_options/mixin/sodium/MixinSliderControlElement.java @@ -118,9 +118,9 @@ private void setValueFromMouseScroll(double amount) { } @Override - public boolean mouseScrolled(double mouseX, double mouseY, double amount) { + public boolean mouseScrolled(double mouseX, double mouseY, double horizontalAmount, double verticalAmount) { if (this.option.isAvailable() && this.sliderBounds.contains((int) mouseX, (int) mouseY) && Screen.hasShiftDown()) { - this.setValueFromMouseScroll(amount); + this.setValueFromMouseScroll(verticalAmount); // todo: horizontal separation return true; } diff --git a/src/main/resources/assets/reeses-sodium-options/lang/es_mx.json b/src/main/resources/assets/reeses-sodium-options/lang/es_mx.json new file mode 100644 index 00000000..cdd93400 --- /dev/null +++ b/src/main/resources/assets/reeses-sodium-options/lang/es_mx.json @@ -0,0 +1,5 @@ +{ + "rso.search_bar_empty": "Opciones de búsqueda...", + "modmenu.summaryTranslation.reeses-sodium-options": "Reemplaza la pantalla de opciones de Sodium", + "modmenu.descriptionTranslation.reeses-sodium-options": "Reemplaza la pantalla de opciones de Sodium con la intención de mejorar la experiencia del usuario" +} diff --git a/src/main/resources/assets/reeses-sodium-options/lang/it_it.json b/src/main/resources/assets/reeses-sodium-options/lang/it_it.json new file mode 100644 index 00000000..e417b501 --- /dev/null +++ b/src/main/resources/assets/reeses-sodium-options/lang/it_it.json @@ -0,0 +1,5 @@ +{ + "rso.search_bar_empty": "Cerca impostazioni...", + "modmenu.summaryTranslation.reeses-sodium-options": "Rimpiazza la schermata delle impostazioni di Sodium", + "modmenu.descriptionTranslation.reeses-sodium-options": "Rimpiazza la schermata delle impostazioni di Sodium con l'intensione di migliorarne la UX" +} diff --git a/src/main/resources/assets/reeses-sodium-options/lang/pl_pl.json b/src/main/resources/assets/reeses-sodium-options/lang/pl_pl.json new file mode 100644 index 00000000..03f0f4ad --- /dev/null +++ b/src/main/resources/assets/reeses-sodium-options/lang/pl_pl.json @@ -0,0 +1,5 @@ +{ + "rso.search_bar_empty": "Wyszukaj opcje...", + "modmenu.summaryTranslation.reeses-sodium-options": "Zastępuje ekran opcji Sodium.", + "modmenu.descriptionTranslation.reeses-sodium-options": "Zastępuje ekran opcji Sodium z zamiarem ulepszenia UX." +} diff --git a/src/main/resources/assets/reeses-sodium-options/lang/vi_vn.json b/src/main/resources/assets/reeses-sodium-options/lang/vi_vn.json new file mode 100644 index 00000000..cf034ee2 --- /dev/null +++ b/src/main/resources/assets/reeses-sodium-options/lang/vi_vn.json @@ -0,0 +1,5 @@ +{ + "rso.search_bar_empty": "Tìm kiếm tùy chọn...", + "modmenu.summaryTranslation.reeses-sodium-options": "Thay thế màn hình tùy chọn của Sodium", + "modmenu.descriptionTranslation.reeses-sodium-options": "Thay thế Màn hình Tùy chọn của Sodium với ý định cải thiện trải nghiệm người dùng" +}