code wiki / _hdl_build / nx_wasm_mineworld_gate.nx

nx_wasm_mineworld_gate.nx

buildroot/runtime/_hdl_build/nx_wasm_mineworld_gate.nx

10453 B220 linesdepth 4pulls 7 transitivereach 0 importersview sourcekind gate/prooftopic wasm
docsdependenciesstructsconstsfunctions

about

nx_wasm_mineworld_gate.nx -- NATIVE gate for the INFINITE procgen voxel world (the Minecraft-procgen rung). T1 DETERMINISM: same seed+view renders byte-identical (checksum) -- twice, fresh. T2 INFINITE+CONTINUOUS: terrain is defined at far/negative coords; |dh/dx| <= 3 across 120 blocks incl. biome borders (the continuous-amplitude blend = no border cliff); far render differs from spawn render. T3 PROCGEN VARIETY + LIAR-KILL: >=5 distinct heights per region, two distant regions differ, >=2 biomes on a strip; NEG-CONTROL: the same variety detector run on a constant "liar" terrain MUST FAIL (detector is real). T4 EDIT PERSISTENCE ACROSS ROAMING (the Minecraft-critical property the fixed 48x48 grid could not do): dig+place via the raycast+edit-table path (exactly what break_at/place_at wrap at base=0), roam the render window 200 blocks away and back -> edits still there, still render (frame checksum changes). T5 CAVES+BEDROCK: natural interior air pockets exist (before any edits); y=0 always solid everywhere. Windows never-brick N/A (pure user-space render); determinism doubles as the re-run-safe proof. license_tier: ORIGINAL

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_f32_hw.nx nx_png.nx nx_wasm_mineworld.nx nx_wasm_mineworld_gate.nx

imports: nx_syscalls.nxnx_f32_hw.nxnx_png.nxnx_wasm_mineworld.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_mmap mem_bytes rend terrain_h0 mw_o2 mw_h2 f32_div f32_of build_R m4_roty m4_identity f32_of ↻ f32_neg fratio f32_div ↻ f32_of ↻ f32_neg ↻ m4_rotx m4_identity ↻ f32_neg ↻ m4_mul f32_of ↻ f32_add f32_mul render_at ensure_pack blk_ptr pack_default_at blk_ptr ↻ blk_set blk_ptr ↻ rgb f32_of ↻ m4_vec4 f32_of ↻ f32_add ↻ f32_mul ↻ f32_int f32_mul ↻

structs

none

consts

none

functions

18func hw(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
called by 1: main calls 1: sys_write
19func pn(v: i64) -> i64
called by 1: main calls 2: sys_mmapsys_write
31func fbsum(base: i64) -> i64
called by 1: main calls 3: fb_offwwhh
38func rend(base: i64, cgx: i64, cgz: i64, ycos: i64, ysin: i64, pcos: i64, psin: i64) -> i64
51func main() -> i64