Multiplayer Games with Unity

In development! Planned release: 3rd Quarter, 2023.

ISBN: 978-1-937336-21-9
Copyright: 2023
Author: Brian G. Burton, Ed.D.

Multiplayer 2D Games with Unity walks through the full process of creating an authoritative Client/Server 2D game.
Using open-source and free tools you will learn the process of communicating with a server and handling game events.

With the open-source server tool Colyseus, this textbook walks through the entire process of creating a multiplayer game for virtual reality or desktop play with the Unity Game Engine.

Free Email Updates on Multiplayer Game Dev book
We respect your privacy.

Table of Contents:

Preface

Chapter 0: Before We Begin
Our Goal
How We Will Reach Our Goal
Chapter 1: Saying Hello
Learning Objectives
Terminology
An Introduction to Multiplayer Games
What is a server or a host?
What is a client?
Types of Game Servers
Colyseus Hello World
Things you will need
Creating a Game Environment
Adding a Player
Adding Movement to the Player
Adding the Multiplayer Client
Adding the Colyseus Network Manager
Colyseus State
Player.cs
State.cs
The Colyseus Client
Sending information to the server
Receiving Information from the server
Time to connect!
Conclusion
Questions
Exercises

Chapter 2: Understanding Client/Server
Learning Objectives
Terminology
Client/Server Architecture
Simplified Client/Server
Full-scale Client/Server
Local vs. Remote Servers
TypeScript
Configuring a local server
Launching your local server
Index.ts
arena.config.ts
Chap1_2D.ts
Debugging in Localhost
Colyseus APIs Used
Conclusion
Questions

Chapter 3: Making the Client Game Environment
Learning Objectives
Terminology
Game Design
A New Scene
Player Rotation
Client Implementation of Player Rotation
Server Implementation of Player Rotation
Adding the player’s name
Client Implementation of player’s name
Health and Scoring
Client Implementation of Health and Scoring
Server Implementation of Health and Scoring
Conclusion
Questions
Exercises

Chapter 4: Adding Combat
Learning Objectives
Terminology
Combat
Client Implementation of Combat
Server Implementation of Combat
Conclusion
Questions
Exercises

Chapter 5: Configuring an Arena Server
Learning Objectives
Terminology
First Things First
Compiling TypeScript
Arena
Managing your server
Uploading your script
Updating your client for Arena
Conclusion
Questions
Exercises

Chapter 6: Adding a Server Lobby
Learning Objectives
Terminology
Configuring a Lobby
Ship Selection
Winning the Game
Conclusion
Questions
Exercises

Chapter 7: Publishing
Learning Objectives
Terminology
Conclusion
Questions
Exercises

Chapter 8: Next Steps