giovedì 17 gennaio 2013

Cheating in Ruzzle

Hello people! :)

Yesterday my girlfriend was playing around with this game Ruzzle and observing it quickly I decided to try a game.

Results? I suck in Ruzzle! :D I completely can't get a sufficient streak of words in order to win and be satisfied of myself. Of course this wasn't good in any way because meh.. I hate losing!

So after an other quick look I decided to cheat, but not in any simple way or buying some ridicolous apps. Also I don't intend to alter the game executable in any way or use fake calls. That's noob cheating and... well, we're not noobs, are we? ;)

I opened up Geany and started writing a simple Ruzzle Solver in python that takes in input the board and compute every possible path into the ruzzle board. My solver actually just prints the found words on the board and starts inspecting on the top-left corner of the grid.

Is it efficient? No. It's a bruteforce and there could be many tunes in order to make it more efficient, some of them language dependant.

Is it enough? Quite yes. For now, I can average 500/600 points a match with peaks to 800/900 with the right words. The real problem is that you still NEED to find the words on the grid. RS can also print the path to the word, as it save the current state for that word, but it would be too slow to actually see the path and follow it. I found particularly efficient to do it in 2, one speaking the words out loud and the other one founding the on the grid. Also I make it run in 4 different sessions on a i7 quadcore, (I hope it's parallelized al least a bit) one for the words with len=5, one for 6, 7 and 8. Note that there are usually plenty of 5ies, many 6ies some 7ies and the 8ies is quite rare to find, maybe 3 or 4 for match in lucky.

Can I get it and experiment? Yes of course! It's located here, with an italian dictionary (unfortunately hardcoded, I was lazy :P) and you can experiment as much as you like! You can also modify it following the GPLv2 License.

Last request? Leave feedback! I'm curious about your feedback on this cheat. Use the comment area above! :)