code wiki / _hdl_build / nx_wasm_craft_gate.nx

nx_wasm_craft_gate.nx

buildroot/runtime/_hdl_build/nx_wasm_craft_gate.nx

95407 B2097 linesdepth 5pulls 12 transitivereach 0 importersview sourcekind gate/prooftopic wasm
docsdependenciesstructsconstsfunctions

about

nx_wasm_craft_gate.nx -- verifies the GENERATED 3D WORLD natively (same base-relative code the wasm runs). The DDA renderer is checked against GROUND TRUTH (a direct grid scan says what the ray must hit), edits are causal (break removes THE targeted voxel, place fills its face-neighbor), the world loop is deterministic, and the input layer's edge contract holds inside the wired game (E held two frames breaks exactly ONE block). PNGs land in knowledge/ for the eyeball + critics. license_tier: ORIGINAL expect_exit: 0

dependencies 3 imports · 0 importers

nx_wasm_craft.nx nx_png_write.nx nx_gate_verdict.nx nx_wasm_craft_gate.nx

imports: nx_wasm_craft.nxnx_png_write.nxnx_gate_verdict.nx

imported by: nobody (leaf or entry point)

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

main vw init_impl init_impl_v wc_spec wsp wpack wst ejp wsp ↻ genworld wst ↻ gencol wsp ↻ wheight wsp ↻ wnoise wclamp wnoise3 whash whash ↻ vset vin wvx gentrees wsp ↻ wst ↻ wheight ↻ whash ↻ vset_box vset ↻ wc_wmax wst ↻ genmobs mobp en_init en_o_gen en_o_alive en_cap en_o_dense

structs

none

consts

10const K_MAGIC_1000000007: i64 = 1000000007
11const K_MAGIC_4096: i64 = 4096
12const K_MAGIC_20260728: i64 = 20260728
13const K_MAGIC_3000: i64 = 3000
14const K_MAGIC_999999: i64 = 999999
15const K_MAGIC_12345: i64 = 12345
16const K_MAGIC_424242: i64 = 424242
17const K_MAGIC_1024: i64 = 1024
18const K_MAGIC_1536: i64 = 1536
19const K_MAGIC_6144: i64 = 6144
20const K_MAGIC_8191: i64 = 8191
21const K_MAGIC_57344: i64 = 57344
22const K_MAGIC_4611686018427387903: i64 = 4611686018427387903

functions

24func vw(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
25func vn(v: i64) -> i64
called by 1: main
37func emit(base: i64, path: *u8) -> i64
called by 1: main calls 2: wfbnx_png_write_rgb
50func fbck(base: i64) -> i64
called by 1: main calls 1: wfb
57func nblocks(base: i64) -> i64
called by 1: main calls 1: vget
68func main() -> i64