I've been looking into MC's world spawning mechanics - slime chunks to be more specific - and I discovered that it works with a random number generator with seeds. Is there an algorithm to this generator? I would really like to be able to find slimechunks using a calculator instead of a program
. I've tried to Google it, but once again, he isn't my friend.
The slime chunk algorithm is:
Random rnd = new Random(seed + (long) (xPosition * xPosition * 0x4c1906) + (long) (xPosition * 0x5ac0db) + (long) (zPosition * zPosition) * 0x4307a7L + (long) (zPosition * 0x5f24f) ^ 0x3ad8025f);
return rnd.nextInt(10) == 0
P.S. I do have some basic knowledge of languages like Java and C (I can understand the algorithm above), but I'm no expert in it whatsoever, especially not in Java.