diff --git a/gradle.properties b/gradle.properties index 45325de4..c67d892e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,9 +10,9 @@ maven_group = juliand665 archives_name = dynamic-fps # File naming version -minecraft_version = 1.21.2 +minecraft_version = 1.21.0 # Version for publishing -minecraft_version_min = 1.21.2 -minecraft_version_max = 1.21.4 +minecraft_version_min = 1.21 +minecraft_version_max = 1.21.1 enabled_platforms=fabric,forge,neoforge,quilt diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 43908e6c..4e6910b3 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,14 +1,14 @@ [versions] -minecraft = "1.21.3" +minecraft = "1.21" # Platform libraries fabric_loader = "0.15.10" -fabric_api = "0.102.2+1.21.2" +fabric_api = "0.100.1+1.21" -forge = "1.21.3-53.0.7" +forge = "1.21-51.0.33" -neoforge = "21.3.0-beta" +neoforge = "21.0.143" quilt_loader = "0.25.0" diff --git a/platforms/common/src/main/java/dynamic_fps/impl/DynamicFPSMod.java b/platforms/common/src/main/java/dynamic_fps/impl/DynamicFPSMod.java index 8a1afbc9..71b3d9a9 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/DynamicFPSMod.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/DynamicFPSMod.java @@ -263,7 +263,7 @@ private static void checkForStateChanges() { checkForStateChanges0(); } else { // Schedule check for the beginning of the next frame - minecraft.schedule(DynamicFPSMod::checkForStateChanges0); + minecraft.tell(DynamicFPSMod::checkForStateChanges0); } } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/compat/GLFW.java b/platforms/common/src/main/java/dynamic_fps/impl/compat/GLFW.java index 0c3bb626..67f1f5e7 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/compat/GLFW.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/compat/GLFW.java @@ -31,7 +31,7 @@ public static void applyWorkaround() { // Agrees that the window is focused. The mod is // A little too fast for this, so we schedule it // For the next client tick (before next frame). - minecraft.schedule(minecraft.mouseHandler::grabMouse); + minecraft.tell(minecraft.mouseHandler::grabMouse); } } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/config/option/IdleCondition.java b/platforms/common/src/main/java/dynamic_fps/impl/config/option/IdleCondition.java index eec4ac24..cc96914f 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/config/option/IdleCondition.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/config/option/IdleCondition.java @@ -2,6 +2,5 @@ public enum IdleCondition { NONE, - VANILLA, ON_BATTERY; } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BaseToast.java b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BaseToast.java index a37d9e1e..b05fdb4f 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BaseToast.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BaseToast.java @@ -2,11 +2,9 @@ import dynamic_fps.impl.util.ResourceLocations; import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Font; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.toasts.Toast; -import net.minecraft.client.gui.components.toasts.ToastManager; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.gui.components.toasts.ToastComponent; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceLocation; import org.jetbrains.annotations.NotNull; @@ -14,7 +12,6 @@ public class BaseToast implements Toast { private long firstRender; - private Visibility visibility; protected Component title; protected Component description; @@ -28,47 +25,32 @@ protected BaseToast(Component title, Component description, @Nullable ResourceLo this.description = description; this.icon = icon; - - this.visibility = Visibility.SHOW; - } - - @Override - public @NotNull Visibility getWantedVisibility() { - return this.visibility; } @Override - public void update(ToastManager toastManager, long currentTime) { - if (this.firstRender == 0) { - return; - } - - if (currentTime - this.firstRender >= 5000.0 * toastManager.getNotificationDisplayTimeMultiplier()) { - this.visibility = Visibility.HIDE; - } - } - - @Override - public void render(GuiGraphics graphics, Font font, long currentTime) { + public @NotNull Visibility render(GuiGraphics graphics, ToastComponent toastComponent, long currentTime) { if (this.firstRender == 0) { this.onFirstRender(); this.firstRender = currentTime; } - // type, resource, x, y, ?, ?, width, height, width, height - graphics.blit(RenderType::guiTextured, BACKGROUND_IMAGE, 0, 0, 0.0f, 0, this.width(), this.height(), this.width(), this.height()); + // resource, x, y, z, ?, ?, width, height, width, height + graphics.blit(BACKGROUND_IMAGE, 0, 0, 0.0f, 0.0f, this.width(), this.height(), this.width(), this.height()); int x = 8; if (this.icon != null) { x += 22; - graphics.blit(RenderType::guiTextured, MOD_ICON, 2, 2, 0.0f, 0, 8, 8, 8, 8); - graphics.blit(RenderType::guiTextured, this.icon, 8, 8, 0.0f, 0, 16, 16, 16, 16); + graphics.blit(MOD_ICON, 2, 2, 0.0f, 0.0f, 8, 8, 8, 8); + graphics.blit(this.icon, 8, 8, 0.0f, 0.0f, 16, 16, 16, 16); + } graphics.drawString(Minecraft.getInstance().font, this.title, x, 7, 0x5f3315, false); graphics.drawString(Minecraft.getInstance().font, this.description, x, 18, -16777216, false); + + return currentTime - this.firstRender >= 5000.0 * toastComponent.getNotificationDisplayTimeMultiplier() ? Toast.Visibility.HIDE : Toast.Visibility.SHOW; } public void onFirstRender() {} diff --git a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryToast.java b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryToast.java index 4d2427cf..7720601e 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryToast.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryToast.java @@ -23,7 +23,7 @@ public static void queueToast(Component title, ResourceLocation icon) { queuedToast.icon = icon; } else { queuedToast = new BatteryToast(title, icon); - Minecraft.getInstance().getToastManager().addToast(queuedToast); + Minecraft.getInstance().getToasts().addToast(queuedToast); } } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryTracker.java b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryTracker.java index f6bf2014..8441cebe 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryTracker.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/BatteryTracker.java @@ -105,7 +105,7 @@ private static void updateState() { changed = true; int current = charge; - minecraft.schedule(() -> DynamicFPSMod.onBatteryChargeChanged(current, newCharge)); + minecraft.tell(() -> DynamicFPSMod.onBatteryChargeChanged(current, newCharge)); } if (readInitialData && status != newStatus) { @@ -113,7 +113,7 @@ private static void updateState() { State current = status; State updated = newStatus; - minecraft.schedule(() -> DynamicFPSMod.onBatteryStatusChanged(current, updated)); + minecraft.tell(() -> DynamicFPSMod.onBatteryStatusChanged(current, updated)); } charge = newCharge; diff --git a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/ErrorToast.java b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/ErrorToast.java index a827e2a2..1767e394 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/ErrorToast.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/feature/battery/ErrorToast.java @@ -17,6 +17,6 @@ private ErrorToast(Component description) { */ public static void queueToast(Component description) { ErrorToast toast = new ErrorToast(description); - Minecraft.getInstance().getToastManager().addToast(toast); + Minecraft.getInstance().getToasts().addToast(toast); } } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/feature/state/OptionHolder.java b/platforms/common/src/main/java/dynamic_fps/impl/feature/state/OptionHolder.java index b4e4501a..e9e1130a 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/feature/state/OptionHolder.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/feature/state/OptionHolder.java @@ -4,7 +4,7 @@ import net.minecraft.client.CloudStatus; import net.minecraft.client.GraphicsStatus; import net.minecraft.client.Options; -import net.minecraft.server.level.ParticleStatus; +import net.minecraft.client.ParticleStatus; /* * Helper for saving, overriding, and re-applying vanilla options. diff --git a/platforms/common/src/main/java/dynamic_fps/impl/mixin/FramerateLimitTrackerMixin.java b/platforms/common/src/main/java/dynamic_fps/impl/mixin/FramerateLimitTrackerMixin.java deleted file mode 100644 index c0cb1077..00000000 --- a/platforms/common/src/main/java/dynamic_fps/impl/mixin/FramerateLimitTrackerMixin.java +++ /dev/null @@ -1,99 +0,0 @@ -package dynamic_fps.impl.mixin; - -import com.mojang.blaze3d.platform.FramerateLimitTracker; -import dynamic_fps.impl.Constants; -import dynamic_fps.impl.DynamicFPSMod; -import dynamic_fps.impl.PowerState; -import dynamic_fps.impl.config.DynamicFPSConfig; -import dynamic_fps.impl.config.option.IdleCondition; -import net.minecraft.client.Minecraft; -import net.minecraft.client.Options; -import org.spongepowered.asm.mixin.Final; -import org.spongepowered.asm.mixin.Mixin; -import org.spongepowered.asm.mixin.Shadow; -import org.spongepowered.asm.mixin.Unique; -import org.spongepowered.asm.mixin.injection.At; -import org.spongepowered.asm.mixin.injection.Inject; -import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; - -@Mixin(FramerateLimitTracker.class) -public class FramerateLimitTrackerMixin { - @Shadow - @Final - private Options options; - - @Shadow - @Final - private Minecraft minecraft; - - @Shadow - private int framerateLimit; - - @Inject(method = "getFramerateLimit", at = @At("HEAD"), cancellable = true) - private void getFramerateLimit(CallbackInfoReturnable callbackInfo) { - PowerState state = DynamicFPSMod.powerState(); - - if (state != PowerState.FOCUSED) { - // Instruct Minecraft to render a minimum of 15 FPS - // Going lower here makes resuming again feel sluggish - callbackInfo.setReturnValue(Math.max(this.getFramerateTarget(), 15)); - } else { - IdleCondition condition = DynamicFPSConfig.INSTANCE.idle().condition(); - - // Bypass all the vanilla idle checking code - // Note: If Dynamic FPS thinks the user is idle the power state would be different above - if (condition != IdleCondition.VANILLA) { - // Since we're bypassing the idle checking code we also need to set the menu FPS here as it's bundled now - if (isInLevel() || !DynamicFPSConfig.INSTANCE.uncapMenuFrameRate()) { - callbackInfo.setReturnValue(this.framerateLimit); - } else { - callbackInfo.setReturnValue(this.getMenuFramerateLimit()); - } - } - } - } - - /** - * Conditionally bypasses the main menu frame rate limit while using the vanilla idle code. - *

- * This is done in two cases: - * - The window is active, and the user wants to uncap the frame rate - * - The window is inactive, and the current FPS limit should be lower - */ - @Inject(method = "getFramerateLimit", at = @At(value = "CONSTANT", args = "intValue=60"), cancellable = true) - private void getMenuFramerateLimit(CallbackInfoReturnable callbackInfo) { - int limit = this.getFramerateTarget(); - - if (DynamicFPSMod.powerState() != PowerState.FOCUSED) { - // Vanilla returns 60 here - // Only overwrite if our current limit is lower - if (limit < 60) { - callbackInfo.setReturnValue(limit); - } - } else if (DynamicFPSConfig.INSTANCE.uncapMenuFrameRate()) { - callbackInfo.setReturnValue(this.getMenuFramerateLimit()); - } - } - - @Unique - private int getFramerateTarget() { - return DynamicFPSMod.targetFrameRate(); - } - - @Unique - private int getMenuFramerateLimit() { - if (this.options.enableVsync().get()) { - // VSync will regulate to a non-infinite value - return Constants.NO_FRAME_RATE_LIMIT; - } else { - // Even though the option "uncaps" the frame rate the limit is 250 FPS. - // Since otherwise this will just cause coil whine with no real benefit - return Math.min(this.framerateLimit, Constants.NO_FRAME_RATE_LIMIT - 10); - } - } - - @Unique - private boolean isInLevel() { - return this.minecraft.level != null || this.minecraft.screen == null && this.minecraft.getOverlay() == null; - } -} diff --git a/platforms/common/src/main/java/dynamic_fps/impl/mixin/MinecraftMixin.java b/platforms/common/src/main/java/dynamic_fps/impl/mixin/MinecraftMixin.java index d0ada68b..51392611 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/mixin/MinecraftMixin.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/mixin/MinecraftMixin.java @@ -20,7 +20,7 @@ public class MinecraftMixin { @Shadow @Final - private Window window; + private Window window; @Shadow @Final @@ -36,4 +36,32 @@ private void setScreen(CallbackInfo callbackInfo) { IdleHandler.onActivity(); } + /** + * Conditionally bypasses the main menu frame rate limit. + * + * This is done in two cases: + * - The window is active, and the user wants to uncap the frame rate + * - The window is inactive, and the current FPS limit should be lower + */ + @Inject(method = "getFramerateLimit", at = @At(value = "CONSTANT", args = "intValue=60"), cancellable = true) + private void getFramerateLimit(CallbackInfoReturnable callbackInfo) { + int limit = this.window.getFramerateLimit(); + + if (DynamicFPSMod.powerState() != PowerState.FOCUSED) { + // Vanilla returns 60 here + // Only overwrite if our current limit is lower + if (limit < 60) { + callbackInfo.setReturnValue(limit); + } + } else if (DynamicFPSConfig.INSTANCE.uncapMenuFrameRate()) { + if (this.options.enableVsync().get()) { + // VSync will regulate to a non-infinite value + callbackInfo.setReturnValue(Constants.NO_FRAME_RATE_LIMIT); + } else { + // Even though the option "uncaps" the frame rate the limit is 250 FPS. + // Since otherwise this will just cause coil whine with no real benefit + callbackInfo.setReturnValue(Math.min(limit, Constants.NO_FRAME_RATE_LIMIT - 10)); + } + } + } } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastManagerMixin.java b/platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastComponentMixin.java similarity index 58% rename from platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastManagerMixin.java rename to platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastComponentMixin.java index 7a3eaf4c..52368925 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastManagerMixin.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/mixin/ToastComponentMixin.java @@ -1,17 +1,17 @@ package dynamic_fps.impl.mixin; -import net.minecraft.client.gui.components.toasts.ToastManager; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.Inject; import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; import dynamic_fps.impl.DynamicFPSMod; +import net.minecraft.client.gui.components.toasts.ToastComponent; -@Mixin(ToastManager.class) -public class ToastManagerMixin { - @Inject(method = "freeSlotCount", at = @At("HEAD"), cancellable = true) - private void freeSlotCount(CallbackInfoReturnable callbackInfo) { +@Mixin(ToastComponent.class) +public class ToastComponentMixin { + @Inject(method = "freeSlots", at = @At("HEAD"), cancellable = true) + private void hasFreeSlots(CallbackInfoReturnable callbackInfo) { if (!DynamicFPSMod.shouldShowToasts()) { callbackInfo.setReturnValue(0); } diff --git a/platforms/common/src/main/java/dynamic_fps/impl/mixin/WindowMixin.java b/platforms/common/src/main/java/dynamic_fps/impl/mixin/WindowMixin.java new file mode 100644 index 00000000..6dfcfd9f --- /dev/null +++ b/platforms/common/src/main/java/dynamic_fps/impl/mixin/WindowMixin.java @@ -0,0 +1,28 @@ +package dynamic_fps.impl.mixin; + +import dynamic_fps.impl.PowerState; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.mojang.blaze3d.platform.Window; + +import dynamic_fps.impl.DynamicFPSMod; + +@Mixin(Window.class) +public class WindowMixin { + /** + * Sets a frame rate limit while we're cancelling some or all rendering. + */ + @Inject(method = "getFramerateLimit", at = @At("RETURN"), cancellable = true) + private void onGetFramerateLimit(CallbackInfoReturnable callbackInfo) { + PowerState state = DynamicFPSMod.powerState(); + + if (state != PowerState.FOCUSED) { + // Instruct Minecraft to render a minimum of 15 FPS + // Going lower here makes resuming again feel sluggish + callbackInfo.setReturnValue(Math.max(DynamicFPSMod.targetFrameRate(), 15)); + } + } +} diff --git a/platforms/common/src/main/java/dynamic_fps/impl/util/HudInfoRenderer.java b/platforms/common/src/main/java/dynamic_fps/impl/util/HudInfoRenderer.java index e6f91e18..35e472db 100644 --- a/platforms/common/src/main/java/dynamic_fps/impl/util/HudInfoRenderer.java +++ b/platforms/common/src/main/java/dynamic_fps/impl/util/HudInfoRenderer.java @@ -5,7 +5,6 @@ import dynamic_fps.impl.feature.battery.BatteryTracker; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.Component; import static dynamic_fps.impl.util.Localization.localized; @@ -58,7 +57,7 @@ private static void drawBatteryOverlay(GuiGraphics graphics) { int[] position = config.placement().get(graphics); // resource, x, y, z, ?, ?, width, height, width, height - graphics.blit(RenderType::guiTextured, icon, position[0], position[1], 0.0f, 0, 16, 16, 16, 16); + graphics.blit(icon, position[0], position[1], 0, 0.0f, 0.0f, 16, 16, 16, 16); // font, text, x, y, text color graphics.drawString(minecraft.font, BatteryTracker.charge() + "%", position[0] + 20, position[1] + 4, 0xFFFFFF); } diff --git a/platforms/common/src/main/resources/assets/dynamic_fps/data/default_config.json b/platforms/common/src/main/resources/assets/dynamic_fps/data/default_config.json index 36ccd02d..0f1f9798 100644 --- a/platforms/common/src/main/resources/assets/dynamic_fps/data/default_config.json +++ b/platforms/common/src/main/resources/assets/dynamic_fps/data/default_config.json @@ -3,7 +3,7 @@ "uncap_menu_frame_rate": false, "idle": { "timeout": 300, - "condition": "vanilla" + "condition": "on_battery" }, "battery_tracker": { "enabled": false, diff --git a/platforms/common/src/main/resources/dynamic_fps-common.mixins.json b/platforms/common/src/main/resources/dynamic_fps-common.mixins.json index f930e0a4..b04d0f57 100644 --- a/platforms/common/src/main/resources/dynamic_fps-common.mixins.json +++ b/platforms/common/src/main/resources/dynamic_fps-common.mixins.json @@ -4,14 +4,14 @@ "minVersion": "0.8", "client": [ "DebugScreenOverlayMixin", - "FramerateLimitTrackerMixin", "GameRendererMixin", "GuiMixin", "LoadingOverlayMixin", "MinecraftMixin", "OptionsMixin", "SoundEngineMixin", - "ToastManagerMixin", + "ToastComponentMixin", + "WindowMixin", "bugfix.BlockableEventLoopMixin" ], "mixins": [], diff --git a/platforms/fabric/src/main/resources/fabric.mod.json b/platforms/fabric/src/main/resources/fabric.mod.json index 47e5e59b..082056fa 100644 --- a/platforms/fabric/src/main/resources/fabric.mod.json +++ b/platforms/fabric/src/main/resources/fabric.mod.json @@ -70,7 +70,7 @@ }, "depends": { "fabricloader": ">=0.15.10", - "minecraft": ">=1.21.2", + "minecraft": ["1.21.0", "1.21.1"], "mixinextras": ">=0.3.2", "fabric-resource-loader-v0": "*", "fabric-lifecycle-events-v1": "*" diff --git a/platforms/forge/src/main/java/net/lostluma/dynamic_fps/impl/forge/DynamicFPSForgeMod.java b/platforms/forge/src/main/java/net/lostluma/dynamic_fps/impl/forge/DynamicFPSForgeMod.java index db9c02bf..7dcc19c1 100644 --- a/platforms/forge/src/main/java/net/lostluma/dynamic_fps/impl/forge/DynamicFPSForgeMod.java +++ b/platforms/forge/src/main/java/net/lostluma/dynamic_fps/impl/forge/DynamicFPSForgeMod.java @@ -20,14 +20,14 @@ public class DynamicFPSForgeMod { private static final List TICK_EVENT_LISTENERS = new ArrayList<>(); - public DynamicFPSForgeMod(FMLJavaModLoadingContext context) { + public DynamicFPSForgeMod() { if (FMLLoader.getDist().isDedicatedServer()) { return; } DynamicFPSMod.init(); - context.registerExtensionPoint( + ModLoadingContext.get().registerExtensionPoint( ConfigScreenHandler.ConfigScreenFactory.class, () -> new ConfigScreenHandler.ConfigScreenFactory( (minecraft, screen) -> DynamicFPSMod.getConfigScreen(screen) @@ -37,8 +37,8 @@ public DynamicFPSForgeMod(FMLJavaModLoadingContext context) { MinecraftForge.EVENT_BUS.addListener(this::onClientTick); // MinecraftForge.EVENT_BUS.addListener(this::renderGuiOverlay); - context.getModEventBus().addListener(this::registerKeyMappings); - } + FMLJavaModLoadingContext.get().getModEventBus().addListener(this::registerKeyMappings); + } /* public void renderGuiOverlay(RenderGuiOverlayEvent event) { diff --git a/platforms/forge/src/main/resources/META-INF/mods.toml b/platforms/forge/src/main/resources/META-INF/mods.toml index 6b3a1eda..46918218 100644 --- a/platforms/forge/src/main/resources/META-INF/mods.toml +++ b/platforms/forge/src/main/resources/META-INF/mods.toml @@ -85,6 +85,6 @@ file="META-INF/accesstransformer.cfg" [[dependencies.dynamic_fps]] modId = "minecraft" mandatory = true -versionRange = "[1.21.2,)" +versionRange = "[1.21.0,1.21.1]" ordering = "NONE" side = "CLIENT" diff --git a/platforms/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/platforms/neoforge/src/main/resources/META-INF/neoforge.mods.toml index 5daef2be..65ef0b96 100644 --- a/platforms/neoforge/src/main/resources/META-INF/neoforge.mods.toml +++ b/platforms/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -85,6 +85,6 @@ file="META-INF/accesstransformer.cfg" [[dependencies.dynamic_fps]] modId = "minecraft" mandatory = true -versionRange = "[1.21.2,)" +versionRange = "[1.21.0,1.21.1]" ordering = "NONE" side = "CLIENT" diff --git a/platforms/quilt/src/main/resources/quilt.mod.json b/platforms/quilt/src/main/resources/quilt.mod.json index 7ad45af2..819c0aa7 100644 --- a/platforms/quilt/src/main/resources/quilt.mod.json +++ b/platforms/quilt/src/main/resources/quilt.mod.json @@ -81,7 +81,7 @@ }, { "id": "minecraft", - "versions": ">=1.21.2" + "versions": { "all": [">=1.21.0", "<=1.21.1"]} }, { "id": "mixinextras",