Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Multiplayer Snake Game - JavaScript & Socket.io

Traversy Media via YouTube

Overview

Learn to create a multiplayer snake game using JavaScript and Socket.io in this comprehensive video tutorial. Begin by setting up the HTML and canvas, then progress to painting the snake and establishing a Socket.io server. Connect the frontend to Socket.io, move the game state to the server, and implement a game loop. Master snake controls, develop a home screen for multiplayer functionality, and handle new game creation on the server. Explore adding a second player, managing join game error states, and modifying game mechanics for two players. Conclude with testing, debugging, and achieving a fully functional multiplayer snake game.

Syllabus

- Adrian's Intro.
- Setting up HTML.
- Setting up the canvas.
- Painting the snake.
- Setting up the socketio server.
- Connecting to socketio from frontend.
- Moving game state to the server.
- Adding a game loop.
- Debugging game loop issue.
- Controlling the snake.
- WORKING SNAKE GAME!!.
- Home screen for multiplayer game.
- Handling new game on the server.
- Adding ability for second player to join the game.
- Handling join game error states.
- Modify game mechanics for two players.
- Testing the game.
- Debugging errors.
- Working multiplayer game.
- Outro.

Taught by

Traversy Media

Reviews

Start your review of Multiplayer Snake Game - JavaScript & Socket.io

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.