My first fork! 2048 game

2048 is a viral game, coded by Gabriele Cirulli, a 20 year old web developer. I played the game many times and just for curiously, I tried to figure out how the game is coded. From the source code on Github, it seems that it is a simple game made up of HTML, CSS, and Javascript. I had a look at the Javascript folder and did not understand how the functions work, so I went to search online.

Luckily Udacity had a short course on customizing 2048 game. The course is simple, and can be finished in 2 hours, if you are new to Github, you can take more time.

I forked the 2048 source code from Gabriele’s Github, and cloned it to my desktop. I edited the main.css, which contains code on what is displayed on each type of tile, namely, 2, 4, 8…, I changed the color tile to gif. I also changed the text from brown to green so that user can see the text easier. Lastly, I removed some paragraphs and added Google Analytics.

Overall, the course is good, the instructors did not assume we have advanced knowledge, they demoed the steps on their desktop. Edx and Coursera, the two major MOOC website has a blend of theory and practical, while Udacity seems to offer more practical course, focusing on one-off projects.

My version of 2048 can be played here.

Leave a Reply