Repository navigation
Gleba: the pentapod nests, placed as a real surface places them - #587
Merged
Merged
Conversation
Slice 6. The enemies view draws every gleba-spawner and gleba-spawner-small a real Gleba surface places, and every entity view places them, because a nest in one chunk blocks plants in the next. Over the 1024 window at seed 123456 with every control at its default: 67 of 67 nests at the game's position and nothing else, 2,484 of 2,484 cliffs, and 35,225 of 35,227 other entities with no extras (the two plants stone's tree-removal roll spared). - enemy_base_probability is the Nauvis EnemyBaseField, unchanged, with its frequency doubled (Gleba's formula is exactly twice Nauvis's); it and 10 other fields match the game at 1,280 of 1,280 positions, and the two nest probabilities at 1,131 of 1,131 where the penalty cannot matter. - enemy_autoplace_base's random_penalty is one batch per chunk, row-major at (x + 8, y), evaluated the first time a nest asks. - The small nest occupies its +-1.35 collision box once placed; the apply step tests a new entity's map-gen box against those. - A control at size 0 drops its autoplacers (plants, nests) and their draws; stone carries no control and still draws. Measured with scratch captures; the autoplacer facts test now pins each one's control. - New real-surface fixture (FMW_ARM=nests) with its provenance; the probe gains FMW_PLANTS_SIZE and FMW_STONE_SIZE. The ABI's Gleba block grows 72 -> 88 bytes for the gleba_enemy_base control. - engine.wasm 548,809 -> 554,919 bytes. Render cost in the app: all 1,011 -> 1,082 ms (+7%), terrain unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Kd6o1d34pJNr7M9RVWCV2c
Rebuilt engine.wasm with scripts/build-wasm.sh after the Aquilo and Gleba Rust changes met. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Kd6o1d34pJNr7M9RVWCV2c
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 27 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
Code reviewNo high-signal issues found. This was a light pass over the Rust nest expression module and the stack/resource plumbing in the diff. I did not run the multi-agent review or go through the generated fixtures, the wasm binary or the docs, so this is not a full check for bugs and CLAUDE.md compliance. |
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.
Gleba slice 6: the pentapod nests, placed as a real surface places them (#454)
The
enemiesview now draws everygleba-spawnerandgleba-spawner-smalla real Gleba surface places, andalldraws them with everything else. Every entity view places them, because a nest in one chunk blocks plants in the next. Gleba stays dev-only.Over the 1024 window at seed 123456, every control at its default (the map a player gets):
What it took
enemy_base_probabilityis the NauvisEnemyBaseField, unchanged, with its frequency control doubled, because Gleba's frequency formula is exactly twice Nauvis's. It and 10 other fields matchcalculate_tile_propertiesat 1,280 of 1,280 positions. The two nest probabilities match at 1,131 of 1,131 whererandom_penaltycannot change the value. The other 149 depend on howcalculate_tile_propertiesbatches, which was not measured, so the replay grades those.enemy_autoplace_base(0, 8)is arandom_penaltyover the chunk's 1,024 tiles, row-major, at(x + 8, y). That is the layout Vulcanus's solid ore proved in Reproduce the Vulcanus solid-ore random_penalty roll (#84) #437.prepareAutoplacersdrops an autoplacer whose owncontrolis at size 0. The plants and nests carry a control. Stone and the stromatolites carry none. Measured with scratch captures:map_color. They paint (255, 25, 25), which is what the game's own preview PNG uses (itsdefault_enemy_color), over the collision box.gleba_enemy_basefrequency and size, appended at the end. The Gleba views are now terrain, trees, cliffs, resources, enemies and all.Grades
gleba_nest_fields_match_the_gamegleba_nests_replay_the_real_surface(three 128 windows)gleba_nest_replay_controlsgleba_nests_whole_window(ignored, release)wasmGlebaEntityParity.spec.ts,enemiesviewallviewtrees/resourcesThe nest field and replay tests are in
POISONED_TESTS. Both fail under--features poison.Planted breaks
Each one was planted and the Gleba tests were run against it. All of these went red: the penalty at
x + 0, the penalty's seed at 0, no penalty, a column-major batch, the frequency not doubled, nodistance > 350, the starting-enemies term dropped, the small group before the large one, the nests before stone, the small nest keeping its map-gen box, nests blocking nothing, and the nest groups running at enemy size 0.These are gaps, stated here:
gleba_groups. The game measurement for that rule, and for stone's group still running at size 0, is a check by hand against scratch captures.aux > 0.375to>=stays green.Cost
The app's own preview, Gleba at seed 123456, headless Chrome with no DevTools client, median of 7 runs against the branch point d69e8bc:
terrain: 524 -> 527 ms, no changeall: 1,011 -> 1,082 ms (+7%)engine.wasm grows from 554,359 to 560,416 bytes against current main (8da30ca), rebuilt after merging main in. The timings above were taken before that merge; the merge touched only Aquilo and TS panel code.
Not changed
The Nauvis enemy code is untouched. The Nauvis parity specs and frozen counts pass unchanged.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Kd6o1d34pJNr7M9RVWCV2c