How to get true RNG?
-
Hi.
Many of the retro titles I enjoy are word games.
The starting letters should all be random, but I tend to constantly receive the same patterns on these.
That RNG is probably also true with other games as well.
Is there anything that can be done to completely change this baseline with them?
Hope that I'm making some sense.
Cheers. :)
-
@Addison RNG generators are usually seeded by the system time. Since the Pi doesn't have a clock, it's likely that your RNG is being seeded by 0 every time and that's why you see the same thing over and over.
-
If we're talking about emulated games, the date/time of the emulator may not have an influence on the RNG the game implements - most of the emulated systems didn't have a real time clock or the concept of the system date/time.
@Addison it all depends on how the game implemented the RNG, some of the games relied on the RAM contents to initialize the RNG. On an emulator, the emulated RAM may get initialized to the same value (zero for instance) and thus there's no RNG at stake. Some emulators cater for this kind of situation with options - for instance Snes9x has a Randomize Memory option for this kind of situations, others may initialize the RAM directly with random values to prevent RNG failures.
Funny enough, some games' RNG can be manipulated, a technique used in speedruns to get a predictable set of events/weapons/etc. An example is below, where the runner saves and resets the game during startup
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.