TerrainView draws the island as 16 x 16 chunks of 64 m, each at one of four detail levels (2, 4, 8 and 16 m spacing) chosen by distance to the camera. TerrainChunkBuilder builds chunk geometry on WorkerThreadPool threads; the main thread only uploads finished meshes, within a 2 ms per-frame budget, nearest chunks first. - Seams: every chunk hangs skirts deeper than twice the most any level strays from the full-resolution edge, so neighbours at any two levels meet without a crack. Normals come from the full-resolution heightfield at every level, and back faces light like the ground above them. - Splat material: a procedural shader blends sand, marsh, grass and rock with weights from the island's bands, averaged over 4 m so borders blend. Steep ground turns to rock and summits weather pale. - Collision stays SimGround's heightfield, with no renderer involved. - Capture scenarios terrain, terrain_lod (tinted by level) and terrain_cracks (magenta sky). tools/crack_check.gd counts sky pixels seen through the ground; make terrain-capture requires cracks in a skirtless control and none in the real terrain. Tests: chunk vertices sit on the heightfield; skirts cover every pairing of levels on sampled shared edges; detail falls with distance; flying across the island at 30 m/s for 2,037 frames streams 661 chunk rebuilds with the worst main-thread frame at 0.8 to 1.4 ms (headless, CPU only); 24 players over 900 ticks on two generated islands never sink into the ground, and a player sprints up towards a summit unharmed. make terrain-capture: control 437 crack pixels, terrain 0. Closes #10 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
40 lines
1.1 KiB
Makefile
40 lines
1.1 KiB
Makefile
# Tidewall build entry points. Everything runs headless with the repo-local engine.
|
|
GODOT := tools/godot.sh
|
|
|
|
.PHONY: check import parse test test-selfcheck smoke capture-test terrain-capture binaries verify-engine
|
|
|
|
## Everything that must pass before a push.
|
|
check: verify-engine binaries parse test test-selfcheck smoke
|
|
|
|
verify-engine:
|
|
@$(GODOT) --verify
|
|
|
|
binaries:
|
|
@tools/check_binaries.sh
|
|
|
|
## Refreshes Godot's global class cache, so class_name lookups resolve.
|
|
import:
|
|
@$(GODOT) --import --quit >/dev/null 2>&1 || true
|
|
|
|
parse: import
|
|
@$(GODOT) --script res://tools/parse_all.gd
|
|
|
|
test: import
|
|
@tools/run_tests.sh
|
|
|
|
## Proves the test runner detects each kind of failure.
|
|
test-selfcheck: import
|
|
@tools/test_selfcheck.sh
|
|
|
|
## Boots the headless server for 1,000 ticks and checks exit codes, logs and timing.
|
|
smoke: import
|
|
@tools/smoke.sh
|
|
|
|
## Renders the capture test scenes in the offscreen container. Needs Docker.
|
|
capture-test: import
|
|
@tools/capture_selfcheck.sh
|
|
|
|
## Renders the terrain crack check and its control in the offscreen container. Needs Docker.
|
|
terrain-capture: import
|
|
@tools/terrain_capture_check.sh
|