← Back to the map
Lesson 10

πŸ–₯️ What is a Server?

What is a Server? illustration

You just built and shipped your very own game. πŸŽ‰ Now for the dream: playing it with your best friend across town β€” the same game, at the same moment. But… their computer and your computer are totally separate machines.

So how do they agree on where everyone is standing β€” at the exact same time? Meet the secret hero of every online game: the server.

1

The big idea: one shared brain

Right now your game lives inside yourcomputer's brain (its memory). Your friend's game lives in theirs. Two separate brains can't magically know each other's thoughts.

So we add a third computer in the middle that both connect to: a server. The server keeps the one true versionof the game. Everybody sends their moves to it, and it tells everybody what the world looks like now. It's the referee β€” what it says, goes.

Your computer is called the client. The shared one is the server. A Minecraft β€œrealm” or β€œserver” is exactly this. πŸ–₯️

2

Your turn: be the referee

Below are two screensβ€” yours and your friend's β€” and a server in the middle. Move your red player around, then flip the server on and off and watch what happens to the two screens.

πŸ–₯️
The Server
πŸ“‘ broadcasting the truth
βœ… Both screens agree β€” everyone sees the same game!
πŸ“± Your screen
You
Pal
πŸ“± Friend's screen
You
Pal
Move yourself:

Your friend (blue) wanders on their own. You control the red one.

3

Discovery missions

Try each one, tick it off, then peek at the secret.

0/5
  • βœ…With the server ON, move yourself left and right. Do both screens agree?

  • πŸ”ŒNow turn the server OFF and move. Watch the two screens.

  • πŸ€ͺLeave the server off and let your friend wander too. How bad does it get?

  • πŸ”Turn the server back ON. What happens to the screens?

  • 🧠Think: who decides the β€œreal” position when players disagree?

🌟 You leveled up! You now know:

🎬 Behind the scenes β€” what's next?

In our lab, messages zipped to the server instantly. But the server might be hundreds of miles away! Those messages have to actually travelacross the internet β€” and that takes time. How do they get there, and why does β€œlag” happen? Let's follow a message. πŸ‘‡

πŸ“‘Next stop Β· Lesson 11How Computers Talk β†’Messages zoom across the internet in tiny pieces. How does your game data actually get there?
← Back to the map