07-29-2016, 11:10 AM
NVRAM = Non-Volatile Read Only Memory. Ignore arcade machines for a moment and think about PCs/Macs/Android. Each time you boot up, it remembers key settings from the last time you used it - stuff that isn't on the hard drive/internal memory but is needed to find that your machine has a hard drive/internal memory, for example... That configuration stuff goes into a battery-backed up portion of RAM - that's where the non-volatile comes into it, it is not going to disappear just because the machine switches off (like the content of the rest of RAM will - it is volatile).
OK, back to Arcade machines. Most modern arcade machines are just PCs and so are covered by the above explanation. Older machines have a variety of uses for NVRAM but typically it is used to store the current configuration of the machine - difficulty level, number of coins required for each credit, etc.
Doesn't seem harmful so far, does it? The problem that NVRAM typically hides is that the game needs to have a method of random numbers so that the game doesn't play exactly the same everytime you step up to it.
A few games will do this based on the player's use of the controls and so can be made to act in a certain way depending on player movement. Note that this shouldn't be confused with positioning - DK has positioning tactics especially when it comes to ladders & this is not a random element caused by the player control.
Most games aren't that simple, however, and instead have an algorithm running multiple times per second which alters the random number - the random number is still predictable if someone were to step through the code but it happens sufficiently often that it appears random when the events occur to the player. Such algorithms are called Pseudo-Random Number Generators (PRNG) and are very, very, important in digital security: they can get very complex. Typically, the PRNG is given feedback by multiple sources such as the content of the NVRAM or the player's control. Some machines even have a "white noise" generator - a piece of hardware that generates garbage values which also feeds into the PRNG to change the next likely number. It is this coupling of the NVRAM into the PRNG which causes synchronisation issues when playing back an INP. The INP only records the player inputs and so a complex PRNG which receives only the INP playback but a different NVRAM will produce different results. The speed at which de-synchronisation occurs is often linked to how complex the PRNG is (but need not be). Alas, de-synchronisation is not limited to the PRNG/NVRAM/player control relationship & can be caused by other factors. However, NVRAM is very often the cause of de-synchronisation on play back simply because the PRNG starts with a different value due to the NVRAM content.