0x668143c4…385fsent to0xb1038d97…281f·#12,802,589·view on Etherscan
The random number generator is a bit similar to proof-of-work. The population "mines" a random number, by submitting random nonces. These nonces contribute entropy to a randomly selected generator. The generator that gets the most hits , wins. The nonces are truly random, because they are mutated after they have been committed, using the random number generated in the previous cycle. It is impossible to predict what nonce will hit a winning generator.
mapping (address => bytes32) commit; // The pre-committed nonce
mapping (address => bool) reveal; // Has the person cast their number?
mapping (address => bytes32) mutation;
mapping (uint => uint) points; // Keeps tracks of score
mapping (uint => bytes32) generator; // XOR of all entropy that hit generator
uint leader; // What generator has the highest score?