u/th3originalsin r/Frontend • Recommends
Create Tetris Game Using JavaScript beginners guide
#canvasapi#tetris#vanillajavascript
43K subscribers • 5 videos on Hallway
Beginner. No background in the topic needed.
95K views8 years ago1 recommendation
Game developmentProgramming languagesJavaScriptGame programming
A step-by-step tutorial on building a Tetris game from scratch using vanilla JavaScript and the HTML5 Canvas API.
Tetris is a video game created by Russian designer Alexey Pajitnov in 1985 that allows players to rotate falling blocks strategically to clear levels. Pajitnov claimed he created the name of the game by combining the Greek prefix tetra, which refers to the four squares contained in each block, with the word tennis. And today you're going to create the TETRIS game using JavaScript and HTML (or HTML5). We're not using any framework Just Vanilla JavaScript. This tutorial is created for beginners especially, As I will discuss the logic behind the game first, and try to break down every code line. So you will literally understand everything about the game, and this will make you be able to create the game on your own. If you want to follow along with me when I type in the code, you'll need to download the starter template from GitHub. ----------------------------------------------------------------------------------------------------- | LINKS | ----------------------------------------------------------------------------------------------------- DOWNLOAD SOURCE CODE + STARTER TEMPLATE: codeexplained.org/2018/08/create-tetris-game-using-javascrip… 🌍 Social Media Links. ◾ Facebook : facebook.com/Code.Explained.Official ◾ Twitter : twitter.com/code_explained ◾ Instagram : instagram.com/Code.Explained.Official/ ◾ GitHub : github.com/CodeExplainedRepo 💲 Suppport the Channel Paypal : paypal.me/CodeExplained Buy Me a Coffee: buymeacoffee.com/CodeExplained ----------------------------------------------------------------------------------------------------- | HASH TAGS | ----------------------------------------------------------------------------------------------------- #JavaScript #beginners #jstutorials #JavaScript #Games #JavaScriptGames Introduction PREVIEW of THE GAME TUTORIAL What we should know about the tetris game? Draw a SQUARE The game board The Tetrominoes (tetris pleces) Draw The Tetrominoes objects in JS Thinga we need Piece The construction function Coordinates of a SQUARE Move The active Tetromino draw() AND un Draw() CONTROL the pieces Collision detection Function Update Movement Functions Rotate a Piece Last UPDATE for rotate function Random Piece Function Lock a Piece DROP a piece Improve how we CONTROL a pieceWhat people say. Recommended as a great beginner-friendly project tutorial for learning vanilla JavaScript and game logic.
u/th3originalsin r/Frontend • Recommends
u/th3originalsin r/Frontend • Recommends