How to make a Game like Writing a Tetris game in JavaScript

How to make a Game like Writing a Tetris game in JavaScript

Writing a Tetris game in JavaScript In this episode I write a Tetris game in JavaScript from scratch. We will look at * How to draw on a canvas * Rotating a matrix * Rudimentary requestAnimationFrame listening * Handling keyboard input Since we are writing ES6 this code might not run on all browsers yet. I was running Chrome 53 when I wrote this and if you wish to follow I recommend you do too. The initial HTML can be found here: http://ift.tt/2jitiJu Source code with step-by-step commits: http://ift.tt/2ivBzfX Music: Demoscene Time Machine…continue reading →