A Prompt for a Multiplayer Snake Game
A full brief for an .io style snake arena where the server owns the truth, with the follow-ups to ask and the lag and collision bugs to expect.

Key takeaways
- Say that the server decides every collision and every pellet. Client-side collisions mean two players both think they won.
- Bots that fill a room until real players arrive make the game feel alive from the first visit.
- Plan for drawing many snake segments cheaply from the first build: long snakes are the point of the game.
A multiplayer snake prompt has to say who owns the truth. In an .io arena dozens of snakes move at once, and if every browser decides its own collisions, players see different deaths. The brief below makes the room server authoritative, keeps the controls to one direction and one boost, fills empty rooms with bots, and sets a clear first-version scope. Paste it into Startbase and test it with a few browser windows.
The arena brief
Build a multiplayer snake arena game for the browser called Coil, 2D, for phones and desktop. Players join a room from the title screen by typing a nickname and pressing Play; they land in the fullest room with free space, or a new one, with up to 20 snakes per room counting bots. The arena is a circle about 30 screens wide with a soft glowing edge; touching the edge kills you. Snakes move forward constantly at a base speed and turn toward the pointer on desktop or toward a virtual joystick on phones, with a maximum turn rate so they cannot reverse in place. Hold the mouse button, or a boost button at the bottom right on phones, to move at 1.8x speed while losing one segment every half second; boost stops below 10 segments. Eating glowing pellets grows the snake; the arena keeps a steady number of pellets. If your head touches any other snake's body you die, and your body turns into a trail of large pellets worth more than normal ones. Head-on collisions kill both snakes. The room server owns the game: it runs movement 20 times per second, decides every collision and pellet pickup, and sends positions to players; browsers draw other snakes smoothly between updates and draw their own snake from local input, corrected by the server. When fewer than 8 real players are in a room, add bots that wander, chase pellets and avoid walls, named and colored like players, and remove one bot each time a person joins. HUD: your length, a top 10 list at the top right, and a small minimap of the circle with your position. On death: your final length and rank, and a Play again button that respawns you in the same room within a second. Look: dark background with a faint hex grid, bright neon snakes with simple patterns (stripes, dots, gradient) picked at random, a gentle glow on heads. Sound: a soft pop when eating, a low whoosh while boosting, a crunch on death, no music. First version: no accounts, no skins shop, no teams.
Why these choices
- Server-authoritative collisions. With 20 snakes and network delay, two browsers can disagree about who touched whom first. One referee settles it, and players accept a death they can see replayed the same way everywhere.
- Twenty moves per second with smoothing. Sending positions at a modest rate and drawing smoothly in between keeps bandwidth low and motion fluid. Your own snake responds instantly so steering never feels late.
- Turn rate limit. Without it, a snake can turn 180 degrees into its own body or dodge any attack. The limit is what makes cutting someone off a skill.
- Boost costs length. Boost is the risk-reward heart of this genre: you spend size to make a kill. The 10 segment floor stops tiny snakes from becoming unkillable darts.
- Bodies become bigger pellets. It turns every death into a feeding frenzy, which is why players gather around fights.
- Bots that leave as people arrive. A new game with no players dies on its first day. Bots make the arena feel busy while you find an audience, and stepping aside for real players keeps rooms human as you grow.
- A circle arena with a minimap. A circle has no corners to camp in, and the minimap stops players getting lost in a space thirty screens wide.
The single-player foundations (grid or free movement, growth and self-collision) are in the round-one guide on how to make a snake game. The wider genre, including rooms and matchmaking for many players, is in how to make an .io game.
The first three follow-up prompts
- 01"Open four preview windows and show me the server's tick time and message size per second with 20 snakes, half of them over 200 segments. If either grows too fast, send only the head and length for snakes off a player's screen and rebuild their bodies from the path."
- 02"Add a kill feed in the top left ('Ana cut off Bolt') and a short slow-motion zoom on your own snake for half a second when you make a kill. Keep the server running at normal speed; the effect is only on your screen."
- 03"Add cosmetic patterns players can choose on the title screen: 12 patterns and 10 colors, remembered in the browser. Other players see your choice. No purchases."
Two variations
Team arena
Add: "Two teams, red and blue. Snakes cannot kill teammates; touching a teammate's body just blocks you. The team with the greater total length when a 5 minute round ends wins, then the round restarts." Teams change the play from survival to coordinated cut-offs, and give friends a reason to join the same room.
Single-player with bots only
If you want to start without a server, ask for the same game with "no multiplayer: you play against 15 bots in your browser, with three bot difficulty levels and a best length saved locally." It publishes on any plan and lets you tune the feel before going online. Adding the room server later is a follow-up, not a rewrite, if you mention it in the first brief.
What usually goes wrong and how to ask for the fix
- "I died but I was not touching them." The browser drew the other snake late. Ask: "On death, show the moment of the collision from the server's view for one second, with both snakes where the server had them. Reduce the interpolation delay to 100 milliseconds."
- Your own snake jumps back after turning. Server correction fights local input. Ask: "When the server's position for my snake differs slightly from mine, blend toward it over 200 milliseconds instead of snapping. Only snap if the difference is more than half a screen."
- The game slows down when snakes get long. Each segment is its own sprite. Ask: "Draw each snake body as one textured strip or one batched draw instead of a sprite per segment, and reuse objects for pellets."
- Bots are too smart or suicidal. Ask: "Bots should be beatable: give them a reaction delay of 300 milliseconds, let them boost only when chasing a smaller snake, and keep them away from the arena edge."
- Rooms fill unevenly. Everyone lands in one room while others hold only bots. Ask: "When choosing a room, prefer the one with the most real players that still has space, and close rooms that have had no real players for two minutes."
Hosting and testing
Previews run the room server on every plan, so you can test the whole game before paying for anything. Publishing it with the game happens on paid plans once Multiplayer is on for the project, and published use is billed from credits; the multiplayer docs list the details. Before sharing widely, test with several windows and at least one phone on mobile data, and read the multiplayer guide for reconnect and late-join checks.
Frequently asked questions
How many players can a multiplayer snake game handle?
There is no fixed number. The brief sets 20 snakes per room including bots; measure tick time and message size with that many long snakes before raising it.
Why does the server need to decide collisions?
Every browser sees other snakes slightly late. If each decided its own collisions, two players could both survive or both die in their own view. One server decision keeps everyone consistent.
Do I need a paid plan to test multiplayer?
No. Previews and shared preview links run the room server on every plan. Publishing the game with its hosted room server requires a paid plan.

