User Tools

Site Tools


kirby64_the_crystal_shards:rng

RNG

Kirby 64 uses two types of random number generators in game:

  • A “soft” RNG which iterates through a set of 1024 predetermined 8-bit values, and
  • A “hard” RNG which is your typical seeded pseudo-random number generator.

The soft RNG seed (i.e. the current index of the soft RNG array at 0x8003DF20) is located at 0x8003E320, and the hard RNG is located at 0x8003E324. The next hard RNG value is generated as such:

(D_8003E324 = (D_8003E324 * 0x343FD) + 0x269EC3);
kirby64_the_crystal_shards/rng.txt · Last modified: 2021/02/22 21:45 by someone2639