zoom_in
  • visibility548
posted last year, edited last year

Game: https://phi.pf-control.de/KB/canvas_game_tetr/canvas_tetris.html
The source code is completely commented and available in the HTML-file.
In case you want to see just the code, it's also uploaded here: pastebin.com/jvCmR3Jn

Back then, when flash was dying, people recommended the JavaScript canvas object as a good alternative to make games on.
This was one of my first attempts to try out new HTML5 features, SVG images and making a somewhat nice game from it. ^^

Music/Sound-effects were taken from some free music-sites and credited in page and code.
Without SFX/Music the game could even be self-contained in the HTML file. ^^'

In total, it worked pretty well, and I set this up in around three hours, but for more expansive games, I would recommend using one of the many javascript-libraries.

More From staralternate_emaildediggefeddeSee Morearrow_outward

Similar ArtworksSee Morearrow_outward