Skip to content

dynamicGuiSizeRadiusInPixelsToShow incorrectly changes to 4.9E-324 when set to -1 #103

@INV-PLA

Description

@INV-PLA

Bug Description
When setting dynamicGuiSizeRadiusInPixelsToShow to -1, the value incorrectly changes to 4.9E-324 instead of producing the intended disabled effect.

To Reproduce

Open the mod configuration file

Locate the dynamicGuiSizeRadiusInPixelsToShow setting

Change its value to -1

Save and reload the configuration file

Observe that the value becomes 4.9E-324 instead of remaining -1

Expected Behavior
Setting dynamicGuiSizeRadiusInPixelsToShow to -1 should properly disable the circular cropping effect and retain the value -1.

Mod and Minecraft Version

Mod Version: watut-neoforge-1.21.0-1.2.7

Minecraft Version: 1.21.1

NeoForge Version: 21.1.213

Additional Context
The configuration comment states the valid range as 4.9E-324 ~ 1.7976931348623157E308, but -1 is intended as a special value to disable the feature. Currently, setting it to -1 results in a numerical conversion error, changing it to an extremely small positive value (4.9E-324).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions