Fixed irl days timer not working in prod

master
Wynd 2024-01-08 15:33:03 +02:00
parent 851d5149b4
commit ceba37ea02
2 changed files with 2 additions and 2 deletions

View File

@ -11,7 +11,7 @@ import xyz.pixelatedw.finalbeta.WyHelper;
@Mixin(Level.class) @Mixin(Level.class)
public class LevelMixin { public class LevelMixin {
@Inject(method = "method_242", at = @At(value = "INVOKE", target = "Lnet/minecraft/level/LevelMonsterSpawner;method_1870(Lnet/minecraft/level/Level;ZZ)V")) @Inject(method = "method_242", at = @At("TAIL"))
public void tick(CallbackInfo ci) { public void tick(CallbackInfo ci) {
WyHelper.playTime++; WyHelper.playTime++;
} }

View File

@ -43,7 +43,7 @@ public class OverlayMixin extends DrawableHelper {
public void render(float f, boolean flag, int i, int j, CallbackInfo ci) { public void render(float f, boolean flag, int i, int j, CallbackInfo ci) {
if (ModConfig.ENABLE_TIME_TRACKING.get()) { if (ModConfig.ENABLE_TIME_TRACKING.get()) {
TextRenderer textRenderer = this.minecraft.textRenderer; TextRenderer textRenderer = this.minecraft.textRenderer;
this.drawTextWithShadow(textRenderer, "Days Played: " + WyHelper.getGameDaysPlayed() + " (" + WyHelper.getRealDaysPlayed() + ")", 2, 96, 14737632); this.drawTextWithShadow(textRenderer, "Play Time: " + WyHelper.getGameDaysPlayed() + " (" + WyHelper.getRealDaysPlayed() + ")", 2, 96, 14737632);
} }
} }
} }