Conversation
added 4 commits
August 24, 2026 03:32
Night vision is all-or-nothing today: the toggle drops you straight into the full potion effect. This makes it a curve instead - a lit strength, a dark strength, the light level counted as lit, an exponent for the shape, and a fade speed. VisionHandler recomputes the target every client tick and eases towards it; a GameRenderer mixin returns that value from the night vision scale so the vignette follows it. Off by default (nv_curve = false), so nothing changes unless you turn it on. The Forge mixin block in build.forge.gradle.kts was commented out because there were no mixins to build a refmap from - there is one now, so it goes back in. scripts/NightVisionCurveCheck.java is a plain javac/java -ea check for the curve maths, including the hand-edited-config values the sliders cannot reach.
Sliders for the five curve values plus the toggle, with English, German and Austrian strings.
…categories Adds an optional per-dimension override on top of the global settings. Each dimension gets a subcategory in the config screen with its own auto-enable toggle and curve sliders; the override only starts existing once you tick "Use own settings here", so an untouched config file is unchanged. VisionHandler now owns the join/dimension-change logic that JoinListener had inline, so entering a dimension re-evaluates night vision the same way joining a world does. It also leaves a real night vision potion alone - the curve backs off while one is active instead of fighting it. auto_nv moves from ConfigData up to VisionSettings so an override can carry its own value. Same field name, so existing config files still load.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds per-dimension night vision settings, so different dimensions can have different settings.
No override means it uses the global settings, so existing configs are unaffected.
Based on the curve PR.