The Tokyo Tune Train

I spent this weekend in the Harajuku neighborhood of Tokyo at Music Hack Day Tokyo. Inspired by the Tokyo Subway, and the love many people in Japan have for music games I thought I would build a Tokyo Subway-themed music game for my hack.  The result is the Tokyo Tune Train.

The Tokyo Tune Train

The Tokyo Tune Train

The goal of the game is to drive a Tokyo Subway car through the maze of routes and make it to the final stop with the fewest deviations from the track (in my world, the trains don’t stay on the tracks unless you steer them). It’s a bit like Centipede or Snake, but with a train track and music integrated into the game play.

Tokyo_Tune_TrainFirst_Of_The_Year__Equinox__by_Skrillex

Headlights help you see up coming turns

The movement of the train is synchronized to a song – with every beat of the song, the train advances a hundred feet down the track.  As long as you stay on the track, the song will play perfectly, but if you miss a turn, not only will you veer off the tracks you will also veer into a completely different part of the song.  If you stop the train, the song will stop and continually play that one beat until you start again. If you go backwards the song will play backwards.  You can speed the train up and slow it down (which, of course, also speeds up or slows down the song). A faster train is harder to drive but gets you to the destination quicker.  You get points for good driving and getting to the destination in the quickest time. There’s an adjustable headlight on the train – the brighter the headlight, the further ahead you can see, making the drive easier, but the headlight uses lots of energy, so a brighter headlight will cost you a number of points. You can also drive during the day letting you see the whole line stretched out in front of you. It’s much easier to navigate, but driving during the day costs more points than (access to the tracks during the day is very expensive in my train system). There’s even an autopilot that will take over and drive the train perfectly for you, but it chews through points very rapidly, so use it sparingly.

This is the first game I’ve built in a long time. My goal was to make something that was fun to play in which music was an integral part of the game.

The Technical Bits

At the core of the game is the Echo Nest remix library. I essentially ripped Girl Talk in a Box apart and put in a new play engine that was tied to the game mechanic. The harder bit was figuring out how to build good labyrinth mazes that would get progressively twistier and would fill a 2-D plane.  I played around with a number of algorithms, but none were satisfactory, so instead, I built a maze editor that lets you hand draw mazes and then export the data as json to be used by the app.

Maze_Draw

I enlisted the help of Elissa and Eric to build the mazes. They created 15 awesomely creative mazes that met the needs of the game much better than any maze algorithm, again confirming the superiority of human curators over the algorithm.

Professional maze builders  @elissab and @eswens conducting research at The Scramble

Professional labyrinth builders @elissab and @eswens conducting maze research at The Scramble

I briefly took a look at using Google Play Game service to manage the high-scores, but it looked like it would take at least an hour of precious hacking time to integrate and since it is a feature that wouldn’t appear in the demo, I decided it was not worth the effort.

The Demo

It was a great demo session at Music Hack Day Tokyo. There were easily 150 people crammed into the demo area – it was standing room only.  The demo session was conducted in Japanese, so Taishi provided simultaneous translation for me.  I was nervous giving the demo, so I let the train autopilot do most of the driving.  The crowd seemed to really enjoy the demo, the hack got lots of votes for ‘favorite hack‘ on the hacker league page of hacks, and I got many compliments. I was pleased with the response and feedback

Photo by @timfalls

Taishi translated the demo while I try to drive a train in front of 150 hackers. Photo by @timfalls

A day later I see that a number of people have played the game and have posted their scores to twitter which is great to see (way better response than I received for my dark horse hack).

twitter feedback

twitter feedback

Give the game a try and let me know what you think:

Ride the Equinox line of the Tokyo Tune Train

The code is on github.

  1. #1 by Barry on February 26, 2014 - 12:49 pm

    I could not care less about completing the game. For me the addictive fun was re-mixing Sail by AWOLNation simply by “going off the rails”. Had to force myself to stop playing (and reached something like a -7500 score too)

Follow

Get every new post delivered to your Inbox.

Join 1,315 other followers

%d bloggers like this: