CaffeineMC / sodium

A Minecraft mod designed to improve frame rates and reduce micro-stutter
Other
4.77k stars 811 forks source link

Ability to check the value of a setting #2784

Open Minenash opened 3 weeks ago

Minenash commented 3 weeks ago

Request Description

The ability to get (and preferably set, but I can see the reasons this wouldn't be added) the value of a sodium setting.

My use case is that I'm currently working on a mod that exports screenshots/animations of parts of the world. During export, the world is not rendered. This causes problems with the "Animate Only Visible Textures" setting, as it stops animating animated textures. I don't want to disable it via the fabric.mod.json as there's no reason to disable this feature for the > 99% of the time that the player isn't exporting. The ability to get the value would allow me to add a warning that the setting is on and will cause it to not animate. Though the ability to set would allow the animations to continue to work without decreasing performance the rest of the time, and without making the user toggle it every time they use the mod