apowers313 / NetHackJS

The original NetHack rogue-like game built as a JavaScript WebAssembly module
Other
8 stars 0 forks source link

NetHack PRNG Seed #3

Open apowers313 opened 4 years ago

apowers313 commented 4 years ago

Pass in an argument to libnh to set the PRNG seed so that runs become deterministic and predictable.

apowers313 commented 4 years ago

process_options and sys_random_seed in libnhmain.c

rn2 is defined in rnd.c and Rand is defined in unixconf.h