Skip to content

Terminal - Snowball Game



  • Elf: Tangle Coalbox
  • Location: Speaker UNPreparedness
  • Related to Objective: 11a, 11b

Tangle Coalbox: Howdy gumshoe. I'm Tangle Coalbox, resident sleuth in the North Pole. If you're up for a challenge, I'd ask you to look at this here Snowball Game. We tested an earlier version this summer, but that one had web socket vulnerabilities. This version seems simple enough on the Easy level, but the Impossible level is, well... I'd call it impossible, but I just saw someone beat it! I'm sure something's off here. Could it be that the name a player provides has some connection to how the forts are laid out? Knowing that, I can see how an elf might feed their Hard name into an Easy game to cheat a bit. But on Impossible, the best you get are rejected player names in the page comments. Can you use those somehow? Check out Tom Liston's talk for more info, if you need it.

In this terminal challenge, you will learn about random number generators, specifically the Mersenne Twisters. Based on the hints, you can load multiple versions of this game using the link Snowball2.


Easy and Medium Difficulties

In these difficulties, you can pick your user name. If you start two games with the same number as the name, the game will have an identical starting position. The name is the seed for the random number generator.

You can play multiple identical games to find the position of the enemy, without losing.

Hard Difficulty

In hard mode, you can't type your name. The game picks a random number to seed the game. However, it prints the seed number as your name in the game.


You can use this number to play the game in easy mode in multiple browsers.

Impossible Difficulty

In this difficulty, you can't select or view your name in the game.

Look at the game HTML code for the Impossible Difficulty. At the bottom of the HTML code, there is a list of 624 random numbers. Amazingly enough, this is the exact number of random numbers you need to use the Mersenne Twisters predictor! Copy the numbers at the end of the page. Create a python array with these numbers (using notepad++ and Regex), ex. array = [#,#,...#].


Download the Mersenne Twisters predictor from here. Update the main function of the code to add the array.

myprng = mt19937(0)
array = [#,#,...#]
for i in range(mt19937.n):
    myprng.MT[i] = untemper(array[i])

print ("next random number:", myprng.extract_number())

This will print the random number seed for your impossible level. Grab the number and beat the game in the easy difficulty. Use the pattern you discover in the easy mode to win the impossible mode.



Here are the answers to this challenge in order:

Use the Mersenne Twisters predictor and the 624 random numbers in the game source to predict the random seed for the game's starting position. Use this random number to win the game in easy difficulty. Winning the game in easy will reveal the enemy position in the impossible difficulty.