From 2daf41c7d737b1ee41f34c40a97f3fd9354defed Mon Sep 17 00:00:00 2001 From: Anuken Date: Thu, 9 Oct 2025 22:40:52 +0900 Subject: [PATCH] iOS uncap framerate option --- core/assets/bundles/bundle.properties | 1 + core/src/mindustry/ui/dialogs/SettingsMenuDialog.java | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/core/assets/bundles/bundle.properties b/core/assets/bundles/bundle.properties index 4c34d9d6bb..7c120ac81a 100644 --- a/core/assets/bundles/bundle.properties +++ b/core/assets/bundles/bundle.properties @@ -1277,6 +1277,7 @@ setting.smoothcamera.name = Smooth Camera setting.detach-camera.name = Free Camera setting.detach-camera.description = If enabled, the camera moves independently of the player unit.\nThis setting can be assigned a hotkey. setting.vsync.name = VSync +setting.iosuncapfps.name = High Refresh Rate setting.pixelate.name = Pixelate setting.minimap.name = Show Minimap setting.coreitems.name = Display Core Items diff --git a/core/src/mindustry/ui/dialogs/SettingsMenuDialog.java b/core/src/mindustry/ui/dialogs/SettingsMenuDialog.java index 00af57a731..f494ba2c61 100644 --- a/core/src/mindustry/ui/dialogs/SettingsMenuDialog.java +++ b/core/src/mindustry/ui/dialogs/SettingsMenuDialog.java @@ -412,6 +412,13 @@ public class SettingsMenuDialog extends BaseDialog{ return s + "%"; }); + if(ios){ + graphics.checkPref("iosuncapfps", false, b -> Core.graphics.setPreferredFPS(b ? 0 : 60)); + if(Core.settings.getBool("iosuncapfps")){ + Core.graphics.setPreferredFPS(0); + } + } + if(!mobile){ graphics.checkPref("vsync", true, b -> Core.graphics.setVSync(b)); graphics.checkPref("fullscreen", false, b -> {