Add Camera Shake Edit + option to not save voice chat

This commit is contained in:
Moulberry committed 2024-09-01 18:33:51 +08:00
1 parent 2fbe1f5480
commit 0c6ddc2427
7 files changed
+126 -16

No files matched your search

@@ -55,9 +55,14 @@ public class FlashbackConfig {
@OptionCaption("flashback.option.local_player_updates_per_second")
@OptionDescription("flashback.option.local_player_updates_per_second.description")
@IntOptionRange(min = 20, max = 120, step = 20)
@OptionIntRange(min = 20, max = 120, step = 20)
public int localPlayerUpdatesPerSecond = 20;
@OptionCaption("flashback.option.record_voice_chat")
@OptionDescription("flashback.option.record_voice_chat.description")
@OptionIfModLoaded("voicechat")
public boolean recordVoiceChat = false;
public Set<String> openedWindows = new HashSet<>();
public long nextUnsupportedModLoaderWarning = 0;
@@ -77,6 +82,11 @@ public class FlashbackConfig {
continue;
}
OptionIfModLoaded ifModLoaded = field.getDeclaredAnnotation(OptionIfModLoaded.class);
if (ifModLoaded != null && !FabricLoader.getInstance().isModLoaded(ifModLoaded.value())) {
continue;
}
OptionInstance.TooltipSupplier tooltipSupplier = OptionInstance.noTooltip();
OptionDescription description = field.getDeclaredAnnotation(OptionDescription.class);
if (description != null) {
@@ -97,7 +107,7 @@ public class FlashbackConfig {
}
}));
} else if (field.getType() == int.class) {
IntOptionRange range = field.getDeclaredAnnotation(IntOptionRange.class);
OptionIntRange range = field.getDeclaredAnnotation(OptionIntRange.class);
if (range == null) {
continue;
}