ModsFinder

NaN is an experimental Fabric mod for Minecraft 1.20.1 that overwrites the core math functions in MathHelper, so the world's arithmetic stops behaving as expected.

FabricClient-side onlyMIT LicenseOpen source1.20.1

What it does

The mod uses a minimal Mixin to replace seven methods in net.minecraft.util.math.MathHelper with overwrite annotations. Operations that normally return numbers are changed to produce NaN, a value that stands for a number-like result that cannot be defined. Because the change reaches the math used across the game, a world created with the mod has its calculations broken from the start.

Creating a new world takes at least five minutes, and the loading progress bar jumps erratically between 3% and 100% while it runs. The author warns against trusting that bar. Installation requires Fabric Loader 0.15.0 or newer and Fabric API, and the mod runs on the client alone, so servers do not need it. Files are published for 1.20.1 under the MIT License, and the source code and issue tracker are public.

Key features

  1. MathHelper overwrites

    Seven methods in MathHelper are replaced through Mixin, changing the math the game depends on.

  2. NaN results

    Mathematical operations return NaN, a result that cannot be defined, instead of a usable number.

  3. Broken world generation

    Terrain and world creation run on the altered math, and world creation can take several minutes.

  4. Command-free setup

    The mod is placed in the mods folder and the game is launched with a new world, with no commands to run.

Compatibility

Latest build for each game version and loader.

1.20.11.0
ReleaseBetaAlphaNot available

Only full game releases are shown. This mod publishes no snapshot builds.

Requirements

Dependencies declared by the latest file for each loader.

Required 1

Fabric APILightweight and modular API providing common hooks and intercompatibility measures utilized by mods using the Fabric toolchain.
Required

Use cases

Experimental worlds

Players who want to see Minecraft's math collapse can create a fresh world with the mod for a deliberately chaotic test.

Mod development reference

Developers studying Mixin overwrite annotations can read a short example of replacing vanilla methods in MathHelper.

Who it’s for: The mod suits players looking for chaos in a single-player world and developers interested in how Mixin overwrites vanilla methods. It is not meant for regular survival play, because the altered math affects the whole world.

Questions

Does NaN need Fabric API?

Yes. Fabric API is required, along with Fabric Loader 0.15.0 or newer, on Minecraft 1.20.1.

Do servers need to install NaN?

No. Only the player's game needs it, and servers run without it.

Can an existing world be used with NaN?

The mod changes the core math from the start, so a world created before installing it does not get the same effect. A new world is recommended.

More from xiaofanforfabric

All projects

What the author says

NaN is an experimental Fabric mod that overwrites core mathematical functions in MathHelper using minimal Mixin code, twisting Minecraft's world into an indescribable Cthulhu dimension. NaN 是一个实验性 Fabric 模组,用极少的 Mixin 代码覆盖 MathHelper 中的核心数学函数,将 Minecraft 的世界扭曲成一个不可名状的克苏鲁维度。
xiaofanforfabric, on the Modrinth page

Official listing

Owner
xiaofanforfabric
Published
2026-04-28
Updated on Modrinth
2026-04-28
Facts verified
2026-10-15