Compare commits

..

2 Commits

Author SHA1 Message Date
ee3879dbf3 Update to 1.20.1 2023-08-28 22:37:21 -06:00
02227b5a7d Update to 1.20 2023-08-28 22:31:56 -06:00
9 changed files with 44 additions and 44 deletions

View File

@ -26,7 +26,7 @@ dependencies {
// Fabric API. This is technically optional, but you probably want it anyway. // Fabric API. This is technically optional, but you probably want it anyway.
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}" modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"
modImplementation files("libs/cmods-1.1.0-dev.jar") modImplementation files("libs/cmods-1.2.0-dev.jar")
modCompileOnly "com.terraformersmc:modmenu:4.1.1" modCompileOnly "com.terraformersmc:modmenu:4.1.1"
} }

View File

@ -2,13 +2,13 @@
org.gradle.jvmargs=-Xmx2G org.gradle.jvmargs=-Xmx2G
# Fabric Properties # Fabric Properties
# check these on https://modmuss50.me/fabric.html # check these on https://modmuss50.me/fabric.html
minecraft_version=1.19.4 minecraft_version=1.20.1
yarn_mappings=1.19.4+build.1 yarn_mappings=1.20.1+build.10
loader_version=0.14.17 loader_version=0.14.22
# Mod Properties # Mod Properties
mod_version=2.3.0 mod_version=2.4.0
maven_group=cmods maven_group=cmods
archives_base_name=haxxor archives_base_name=haxxor
# Dependencies # Dependencies
# check this on https://modmuss50.me/fabric.html # check this on https://modmuss50.me/fabric.html
fabric_version=0.75.3+1.19.4 fabric_version=0.87.0+1.20.1

View File

@ -4,12 +4,12 @@ import cmods.cmods.client.options.CmodsOptions;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.AutoFarmer; import cmods.haxxor.client.AutoFarmer;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.EmptyWidget; import net.minecraft.client.gui.widget.EmptyWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -61,20 +61,20 @@ public class CropSelectScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
final int column1 = this.width / 2 + column1_offset; final int column1 = width / 2 + column1_offset;
final int column2 = this.width / 2 + column2_offset; final int column2 = width / 2 + column2_offset;
final int startHeight = (int) Math.floor(this.height * startHeight_multiplier) + heightOffset; final int startHeight = (int) Math.floor(height * startHeight_multiplier) + heightOffset;
this.renderBackground(matrices); this.renderBackground(context);
drawCenteredTextWithShadow(matrices, this.textRenderer, Text.translatable("haxxor.options.farmer.crop_select.seeds"), context.drawCenteredTextWithShadow(textRenderer, Text.translatable("haxxor.options.farmer.crop_select.seeds"),
column1 + buttonWidth / 2, startHeight - rowIncrement, 0xffffff); column1 + buttonWidth / 2, startHeight - rowIncrement, 0xffffff);
drawCenteredTextWithShadow(matrices, this.textRenderer, this.title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
drawCenteredTextWithShadow(matrices, this.textRenderer, Text.translatable("haxxor.options.farmer.crop_select.blocks"), context.drawCenteredTextWithShadow(textRenderer, Text.translatable("haxxor.options.farmer.crop_select.blocks"),
column2 + buttonWidth / 2, startHeight - rowIncrement, 0xffffff); column2 + buttonWidth / 2, startHeight - rowIncrement, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -4,11 +4,11 @@ import cmods.cmods.client.options.CmodsOptions;
import cmods.cmods.client.ui.IntegerAdjustWidget; import cmods.cmods.client.ui.IntegerAdjustWidget;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -52,10 +52,10 @@ public class ElevatorOptionsScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
this.renderBackground(matrices); this.renderBackground(context);
drawCenteredTextWithShadow(matrices, this.textRenderer, this.title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -5,11 +5,11 @@ import cmods.cmods.client.ui.IntegerAdjustWidget;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.HaxxorClient; import cmods.haxxor.client.HaxxorClient;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -76,10 +76,10 @@ public class FarmerOptionsScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
this.renderBackground(matrices); this.renderBackground(context);
drawCenteredTextWithShadow(matrices, this.textRenderer, this.title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -4,11 +4,11 @@ import cmods.cmods.client.options.CmodsOptions;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.HaxxorClient; import cmods.haxxor.client.HaxxorClient;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -55,10 +55,10 @@ public class GlowOptionsScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
this.renderBackground(matrices); this.renderBackground(context);
drawCenteredTextWithShadow(matrices, this.textRenderer, this.title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -4,11 +4,11 @@ import cmods.cmods.client.options.CmodsOptions;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.HaxxorClient; import cmods.haxxor.client.HaxxorClient;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -57,15 +57,15 @@ public class HaxxorOptionsScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
renderBackground(matrices); renderBackground(context);
Text versionText = Text.literal("v" + HaxxorClient.version); Text versionText = Text.literal("v" + HaxxorClient.version);
drawCenteredTextWithShadow(matrices, textRenderer, title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
drawTextWithShadow(matrices, textRenderer, versionText, this.width - textRenderer.getWidth(versionText) - 2, context.drawTextWithShadow(textRenderer, versionText, width - textRenderer.getWidth(versionText) - 2,
this.height - textRenderer.fontHeight - 2, 0xffffff); this.height - textRenderer.fontHeight - 2, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -3,11 +3,11 @@ package cmods.haxxor.client.ui;
import cmods.cmods.client.options.CmodsOptions; import cmods.cmods.client.options.CmodsOptions;
import cmods.cmods.client.ui.ToggleButton; import cmods.cmods.client.ui.ToggleButton;
import cmods.haxxor.client.options.HaxxorOptions; import cmods.haxxor.client.options.HaxxorOptions;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget; import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.GridWidget; import net.minecraft.client.gui.widget.GridWidget;
import net.minecraft.client.gui.widget.SimplePositioningWidget; import net.minecraft.client.gui.widget.SimplePositioningWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.screen.ScreenTexts; import net.minecraft.screen.ScreenTexts;
import net.minecraft.text.Text; import net.minecraft.text.Text;
@ -50,10 +50,10 @@ public class UIOptionsScreen extends Screen {
grid.forEachChild(this::addDrawableChild); grid.forEachChild(this::addDrawableChild);
} }
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) { public void render(DrawContext context, int mouseX, int mouseY, float delta) {
this.renderBackground(matrices); this.renderBackground(context);
drawCenteredTextWithShadow(matrices, this.textRenderer, this.title, this.width / 2, 15, 0xffffff); context.drawCenteredTextWithShadow(textRenderer, title, width / 2, 15, 0xffffff);
super.render(matrices, mouseX, mouseY, delta); super.render(context, mouseX, mouseY, delta);
} }
public void removed() { public void removed() {

View File

@ -23,7 +23,7 @@
"depends": { "depends": {
"fabricloader": ">=0.14.10", "fabricloader": ">=0.14.10",
"fabric": "*", "fabric": "*",
"minecraft": "1.19.4", "minecraft": "1.20.1",
"cmods": "1.1.0" "cmods": "1.2.0"
} }
} }