Add config option to disable player animations

This commit is contained in:
Electroblob77
2020-06-07 23:05:50 +01:00
parent 840ef3b3a5
commit 99a9524ee7
4 changed files with 19 additions and 0 deletions
@@ -334,6 +334,8 @@ public final class Settings {
public boolean screenShake = true;
/** <b>[Client-only]</b> Whether to use the screen blink effect for teleportation spells. */
public boolean blinkEffect = true;
/** <b>[Client-only]</b> Whether to use spellcasting animations for players. */
public boolean spellcastingAnimations = true;
/** <b>[Client-only]</b> The position of the spell HUD. */
public GuiPosition spellHUDPosition = GuiPosition.BOTTOM_LEFT;
@@ -1002,6 +1004,13 @@ public final class Settings {
blinkEffect = property.getBoolean();
propOrder.add(property.getName());
property = config.get(CLIENT_CATEGORY, "spellcastingAnimations", true, "Whether to use custom animations for players casting spells. Disable this option if it conflicts with other mods that add player animations.");
property.setLanguageKey("config." + Wizardry.MODID + ".spellcasting_animations");
property.setRequiresMcRestart(true);
Wizardry.proxy.setToNamedBooleanEntry(property);
spellcastingAnimations = property.getBoolean();
propOrder.add(property.getName());
config.setCategoryPropertyOrder(CLIENT_CATEGORY, propOrder);
}