
The score is almost in the range of my average game, which means I’m about as good at Gembine as a random moves generator. I create a new Leiningen project for that, cram together a function that taps a random arrow key with some delay and, voilà! The blind random player scores 11K after about 150 moves. Gembine is not picky about trying an illegal move, so I have enough ammo to create a blind random player. Not bad for 5′ of work, isn’t it? Monkey Business It works! The REPL has a history, so when the first “doto” is executed, the program taps the up key, and I get rewarded with the last executed line (the keyRelease one).Ī second test, with an initial delay, allows me to switch application, and ensure that the key event is really sent to whichever window has the current focus.

There is a nice class in AWT called Robot that allows you to emulate key presses: let’s take it for a spin! $ lein repl Tools of the tradeĪs a language, I pick Clojure it follows my gradient of maximum fun, but it’s also a natural fit: it’s JVM based, and has a REPL. There is a catch, however: each time you make a move, the computer will add a random gem on the side of the board you move from, which means the player should match on average a gem per move to keep up.Īs soon as there are no available moves, the game ends.


When two gems of the same type overlap the gem you moved disappears, the other one gets promoted to the next level, and you score some points. You can check the gameplay video embedded above to get the idea. The game rules are simple: you start with a 4×4 board with some gems, and your objective is to move the gems on the board, as a whole, in a specific direction, to overlap gems of the same type. Just for comparison, my highest score has been about 53k points: I made them on the first play-through, at 2 am – completely groggy – and I never managed to get even near to that ever again.
JYDGE SECRET AREA MOVIE
I watch a movie or go to sleep, and the next day the secret level is there! I need to top 60k points for that. Even some hours or a night of automated play are OK. I want a program that interfaces with Gembine and beats it in a reasonable time. If you have to learn something, fun is the best way, and if you are not enjoying yourself, either be sure to have a very strong motivation or don’t even bother trying. What I would love to do, is to create a program to solve the game for me!ĭue to its simplicity, Gembine is an ideal problem for learning a number of topics but, more than anything, it has the most desirable trait of all for a learning project: it’s a fun, silly thing, and when learning is involved nothing beats a task that’s nothing about time pressure and destination, and all about the journey and the fun of doing it. If I wanted to play gem matching games, I would have probably downloaded a puzzle game in the first place, which is why spending my time mastering Gembine is not an option. I love 10tons’ games, yet I don’t share their love for gem-matching.

It’s from another 10ton’s game – Crimsonland, they embedded it in there too – but the differences are only aesthetic. One thing buggers me, though: in order to reach a specific secret level, you have to beat a challenge that requires you to score more than 60k points in a tiles-matching gem game called “Gembine”, and it’s rather hard. JYDGE by developer 10tons is my latest addiction: it could be superficially categorized as a twin-stick shooter, but it’s a rather new blend of action and stealth with puzzle elements. I have a mixed relationship with Video-games: on one hand, they are a welcome stress vent and have inspired me to learn and become a programmer on the other one, they are a black hole sinking huge amounts of my spare time and energies.
