Time to learn about backend connections with socket.io. There's a lot to cover here, but the most important takeaway is that all game data is stored on the backend and broadcasted to connected users.
This lesson will teach you how to:
- Connect and disconnect players
- Remove enemies
- Install nodemon
- Install socket.io@4.6.1
- Create initial connection
- Create new http server
- Use new http server required for socket.io server
- Listen for a connection event
- Create first player using sockets
- Create multiple players with sockets
- Remove players on disconnect and timeout