Repository navigation
Alexs Caves
Minecraft 1.20.1 / Forge: this page documents that build and its measurements. For the separate 170-control Minecraft 1.21.1 port, see Minecraft 1.21.1 NeoForge.
Four controls for Alex's Caves 2.0.2 (mod id alexscaves). Two are in its magnetism code: one point-of-interest query instead of two, and equipment checked without cloning arrays. One remembers the rare cave biome lookup per column during world generation. One is a fix: the Teletor's spawn setup stays inside the generation region, which stops a crash with C2ME. Background on Generation context fixes. Every switch checks the code it would change against the tested build; another build is left untouched with one WARN line (see How the patches are applied).
| Key | Target | Side | Since | Kind | Result |
|---|---|---|---|---|---|
alexscaves_equipment_enumeration |
Alex's Caves 2.0.2 | BOTH | 1.0.8 | opt | 64 → 0 B per call |
alexscaves_magnet_query |
Alex's Caves 2.0.2 | BOTH | 1.0.2 | opt | one POI query instead of two |
alexscaves_rare_biome_column_memo |
Alex's Caves 2.0.2 | SERVER | 1.0.28 | opt | 112 → 20 ns and 422 → 5 B per lookup |
alexscaves_teletor_generation_context |
Alex's Caves 2.0.2 | BOTH | 1.0.11 | fix | fixes a crash with C2ME |
Since: 1.0.2 · Script (1.0.19 and earlier): bons_and_furious-MagnetUtil.js
Patched: com.github.alexmodguy.alexscaves.server.entity.util.MagnetUtil.tickMagnetism
Mixins (since 1.0.20): MagnetUtilQueryMixin, LivingEntityJumpingAccessor
What upstream did. Ran two nearby-magnet point-of-interest queries per eligible entity per tick, one for attracting and one for repelling magnets.
What the patch does. Runs a single traversal and partitions the results in their original order before the unchanged force callbacks and the rest of the tick.
What stays the same. Force accumulation order, radius, per-tick response, motion, attachment and world-wide magnet operation; no persistent cache and no biome restriction. 1,772 assertions equal, including 250 raw-bit force/velocity comparisons with the original method.
With Collections Of Optimizations (tested 4.4, since 1.0.27). Its option alexscaves.singleMagnetQuery makes the same change. While that option is on, this control steps aside; while it is off, this control applies and leaves COO's copy out, so only one copy runs. See Compatibility and target versions. With both copies (1.0.26 and earlier), Mixin refused COO's wrappers inside this patch and the game crashed on the first magnetism tick.
Measured. The magnetism hotspot was about 3.8 % of sampled server-thread busy time in the profile that motivated this; that is a baseline cost, not a measured saving, because the assertion harness measured equivalence rather than time.
Since: 1.0.8 · Script (1.0.19 and earlier): furious8-magnet.js
Patched: MagnetUtil.isDynamicallyMagnetic
Mixin (since 1.0.20): MagnetUtilEquipmentMixin
What upstream did. Called EquipmentSlot.values() for every full equipment scan; that enum method returns a cloned array each time.
What the patch does. Keeps one private copy and iterates it in the same order.
What stays the same. The Magnetizing-effect check, the feet-only branch, every equipment and tag callback and the early-return order; equipment changes and tag reloads take effect immediately.
Measured. 64 → 0 B per call in both cases. Wall time: miss 31.60 → 35.31 ns (regressed in the final sample after improving in three earlier runs), last hit 32.92 → 31.12 ns. The consistent result is the removed array, not a time saving; it is kept because it is exact.
Target: Alex's Caves 2.0.2 · Side: BOTH · Since: 1.0.11 (first as a patched JAR 2026-09-11) · Kind: fix
Patched: com.github.alexmodguy.alexscaves.server.entity.living.TeletorEntity.finalizeSpawn — 1.0.19 script bons_and_furious-TeletorEntity.js
Mixin (since 1.0.20): TeletorSpawnContextMixin
What upstream did. TeletorEntity.finalizeSpawn drew from the live world's random four times and added its floating weapon entity to the live Level even when it was handed a generation region. On a C2ME worker thread the random read stops generation with a ConcurrentModificationException, and the weapon insertion reaches into the live world from generation.
What the patch does. Takes both the random and the weapon insertion from the supplied region.
What stays the same. Ordinary spawning keeps the original path; weapon choice, equipment and enchantment logic and the Teletor-weapon UUID links are unchanged. Deliberate difference: during generation the four draws come from the region's random (same distribution) and the weapon is saved with the chunk instead of being added to the live world.
Measured. Fixes a C2ME crash. Twelve helper boundary/error cases and 2,000 concurrent operations pass; the actual Forge-transformed original fails on a worker thread, while the patched method passes 16 Teletors and 16 snails per native test with every weapon contained and linked. Together with scuba_gear_generation_context the exact 172-chunk C2ME ocean-ruin replay completes in 65.875 s.
Since: 1.0.28 · Target: Alex's Caves 2.0.2 · Side: SERVER · Kind: opt
Mixin: RareBiomeColumnMixin
Alex's Caves rare-biome lookup once per column. Alex's Caves asks, before every overworld noise-biome lookup, whether a rare cave biome sits at that spot: a Voronoi cell search with two noise samples and its own allocations. The answer does not depend on height, yet a chunk's biome fill asks it for every quart of every section: 3,072 times per 768-high chunk for the same 16 columns. Each world generation thread now keeps the answers for the columns it is filling, keyed by the seed, the column, Alex's Caves' width-randomness setting and its configuration generation, and hands back the object Alex's Caves returned for that key. Every other lookup runs Alex's Caves' own code.
Measured: 112 -> 20 ns and 422 -> 5 B per lookup on real classes (0.34 -> 0.06 ms per 768-high chunk); 907,201 checks identical.
Bons and Furious is licensed GPL-3.0-only with upstream notices retained. Target mod names identify compatibility targets and do not imply endorsement; their code, assets and licenses remain their authors' property. All measurements on this wiki are focused method, phase or reproduction measurements from the pack the mod was built for, taken on the historical build named in each entry; they are not whole-game FPS or TPS promises and are not additive.
Bons and Furious
Minecraft 1.20.1 / Forge 1.0.34
- Home
- Installation and configuration
- How the patches are applied
- All controls
- Measurements and caveats
- Whole-modpack benchmark
- Troubleshooting and log messages
- Generation context fixes
- Version history
Compatibility
- Compatibility
- Known conflicts and workarounds
- Tested mod list
- Redundant mods
- Compatibility and target versions
Controls by mod
- Minecraft (51)
- Forge (6)
- Ad Astra (1)
- Alex's Caves (4)
- Alex's Mobs (2)
- Almost Unified (1)
- AmbientSounds (3)
- Architectury API (1)
- Ars Nouveau (2)
- Artifacts (1)
- Better Combat (1)
- Bosses of Mass Destruction (1)
- Butterflies (1)
- ChunkSending (1)
- CIT Reforged (1)
- Citadel (1)
- CoFH Core (1)
- Colorwheel (1)
- Cooking for Blockheads (1)
- Create (4)
- Critters and Companions (1)
- Cryptic Foes (2)
- Cucumber (1)
- Curios API (6)
- Distant Horizons (17)
- Dungeons Delight (1)
- Dynamic Trees (2)
- Embeddium (13)
- Entity Model Features (4)
- Entity Texture Features (1)
- EntityCulling (1)
- FancyMenu (1)
- Farmer's Delight (2)
- FD Bosses (2)
- Fowl Play (2)
- Fusion (2)
- GeckoLib (5)
- Goblins Tyranny (2)
- Hostile Villages (2)
- Ice and Fire (6)
- ImmediatelyFast (3)
- Immersive Engineering (1)
- Jaden's Nether Expansion (1)
- JEI (7)
- Kiwi (1)
- L2 Library (2)
- Legendary Monsters (1)
- Lionfish API (2)
- ModernFix (4)
- Mowzie's Mobs (1)
- Mutant Monsters (1)
- Nether Depths Upgrade (1)
- Occult (1)
- Oculus (12)
- Oh The Biomes We've Gone (1)
- Particular (1)
- Pehkui (1)
- Pipez (2)
- Placebo (1)
- Presence Footsteps (1)
- Radium Re-Reforged (8)
- Regions Unexplored (1)
- Relics (2)
- Ribbits (1)
- Ryoamic Lights (2)
- Sake's Structures (1)
- Scorched (1)
- Scuba Gear (1)
- Simply Swords (1)
- SlashBlade: Resharped (1)
- Slice & Dice (1)
- Spawn (4)
- Storage Drawers (2)
- Structure Gel API (1)
- Structurify (3)
- TaCZ (2)
- TerraBlender (2)
- Terramity (1)
- Under the Moon (1)
- Valkyrien Skies (15)
- Trackwork model repair
- Living Engineering (moved out in 1.0.20)
Links