Compile the CoffeeScript files to a single pong-coffeescript.js file with the command:
$ ./compile.sh
You can open pong-coffeescript.html directly in your browser using the file:// protocol. However, I recommend you use a real web server. If you have python installed:
$ python -m SimpleHTTPServer
Then browse to http://localhost:8000/pong-coffeescript.html.
Reload the page each time you change something, or check out Guardfile to setup automatic reloading.
Here are the files you should take a look at, in logical order:
pong-coffeescript.htmlis the page containing the<canvas>we render the game on.game.coffeeis the game engine, mainly the game loop.pong.coffeeinitializes the game and the entities.entity.coffeecontains the base class for all game entities.ball.coffeeis the ball entity. Boing!paddles.coffeeis the logic for the player and computer controlled paddles.