Snake

Rooms and setup

Gameplay area offers Circle (default), Sphere, and Torus. In Advanced settings, Visible surface offers 35% and 50% (default). It is blank and disabled for Circle; switching back to Sphere restores its saved selection.

Torus is a flat square whose opposite edges connect. Choose its Side length (20 by default, an integer of at least 4). Your snake stays centered while a subtle square grid, pellets, and other snakes move around it. The grid has about five horizontal and five vertical lines and scrolls with the world so you can see your movement. Its lines continue across connected edges and corners, and objects crossing an edge appear on the opposite edge. Steer continuously toward your pointer or tap. Visible area offers 35%, 50%, or 100% of the square, revealed by a centered circle. The circle is clipped to the square and enlarged to preserve the selected area after clipping; 100% reveals all four corners. Spectators use the score-table eye buttons to follow an active participant; the grid follows that perspective and uses the same visibility and fog. Collisions and bot routes cross connected edges. Waiting-room practice includes the same moving grid, uses the room's settings, and offers Restart without affecting ratings. In every gameplay area, the waiting-room Practice area has Restart beside its heading, instructions above the arena, and settings, scores, and status in an Info section below it.

Any number of registered players may join while a room is waiting. Every joined player must be ready before the host can start, and nobody can join after that. Guests can create public solo rooms that cannot be joined remotely, but they cannot join multiplayer rooms. Every lobby room card offers View, including waiting rooms shown to guests. A registered player who can join a waiting room sees Join beside View. The host chooses a positive integer reward-pellet count, a non-negative integer penalty-pellet count, and a positive integer game-area radius, while human speed and bot speed are positive values that may include decimals. The defaults are 4 reward pellets, 0 penalty pellets, human speed 7, bot speed 7, radius 10, and no bots. A two-column Penalty settings group follows Human speed and Game-area radius. It contains the penalty count, renewal interval, effect, and exactly one effect-specific selector. When the penalty count is 0, the latter three dropdowns are blank and disabled, and their labels are dimmed. Otherwise, renewal offers 1s, 2s, or 5s and defaults to 2s. Penalty effect defaults to Lose points. Points lost offers 1, 2, or 3 and defaults to 1. Freeze movement instead shows Freeze duration, which offers 1s, 2s, or 3s and defaults to 1s. Switching through 0 penalty pellets retains the selected effect and both effect-specific choices. No-pellet timeout offers 10, 30, or 60 seconds and defaults to 30 seconds. Circle pellet density is (reward pellets + penalty pellets) × (1/2)² / gameAreaRadius². Sphere divides this by 4 for its full surface area. Density may not exceed 10%. For denser settings, the warning includes the current density and disables Create Room.

Every room is public to view. A registered room's Joining setting is Open by default. Host approval lets the host Accept or Decline each pending request, while 4-digit passcode requires the exact code chosen at creation. A player may cancel a pending request and stays in any existing waiting room unless accepted. Only the host can see the passcode. Guest solo rooms use Open.

Game ends after has three choices. Select a combined total of 50, 100, or 200 pellets, a time limit of 1, 2, or 3 minutes, or a point target of 20, 30, or 50 points. The highlighted dropdown is active, the point target defaults to 30 points when selected, and the 1-minute time limit is active initially. A room that starts with exactly one human runs its game processor on that player's device for immediate controls while the server verifies its updates for public spectators; it is unrated. Registered rooms that start with two or more humans are server-processed and rated. Guest-created solo rooms remain unrated. Only the selected value is visible; inactive dropdowns are blank, while all labels remain visible. Selecting a dropdown reveals its saved value.

Adding bots

Create Room opens a waiting room with only its creator, ready by default. The host can select Add bot in the host-only actions row below the player list, choose that bot's positive decimal speed in the modal (defaulting to the room's current human speed), and confirm Add bot. A room can have up to bots. Each bot shows its own speed, Automatic bot readiness, and a Remove button for the host. Removing one reopens its slot and preserves the other bots. Adding bots does not start the match: all humans must be ready before the host selects Start Game. Solo starts without bots remain valid. Bots do not prevent registered humans from joining or change joining policies, requests, or invitations. Guest rooms remain isolated. Recreated rooms also start without bots.

Starting countdown

All human and bot snakes begin at a random valid position. A five-second countdown appears where elapsed time will later be shown. Players can move and change direction freely during the countdown, but no pellets exist and nothing can be eaten. The Circle bot moves toward the center; the Sphere bot follows random search directions. Pellets appear and elapsed time begins when the countdown reaches 00:00. The no-pellet timeout and any configured penalty-renewal schedule also start then, so the countdown itself never uses any of either duration. During gameplay, a warning appears below the game-state progress box at five seconds remaining and counts down once per second through 1s. Eating either pellet type resets the deadline and hides the warning.

The arena and pellets

In Sphere, snakes have radius 1 and pellets have radius 0.5, with their centers on the gameplay sphere of radius M. Snakes move on great circles at their configured surface speed. Contact uses the 3D distance between centers, including the complete movement arc. The circular map remains centered on your snake and shows the selected fraction of the sphere; 50% is one hemisphere. Other snakes and pellets outside that view are hidden. Spectators and resigned players choose their viewpoint with Follow player.

In Circle, the arena is a circle of radius R. Every snake is a circle of radius 1, so its center stays within radius R−1. Snakes may touch, overlap, and pass through one another. Every human snake displays that player's avatar inside its circle, while each bot shows a robot icon. When circles overlap, your own active snake appears in front. All other circles keep room order, with bots after the human players. Every pellet is a circle of radius 0.5. Decorative outlines stay inside those radii, so visible edge contact matches collision contact. Reward pellets are green and add 1 point. Penalty pellets are red. Lose points subtracts the selected number without taking a score below 0. Freeze movement leaves the eater's score unchanged and prevents only that snake from moving for the selected duration. A new pellet may not touch another pellet or any active snake. The server tries at most 1,000 random candidates for each pellet. If setup cannot place them all, Start asks the host to use fewer pellets or a larger radius. If a replacement cannot be placed during play, the game reports that no new pellet can be placed and tries again at the next pellet replacement.

A snake eats a pellet when its swept movement path comes within 1.5 units of the pellet's center. The pellet disappears, its configured reward or penalty effect is applied, and the no-pellet timeout resets from that exact collision, even when a points penalty cannot lower an already-zero score. A movement freeze still accepts new destinations and resumes toward the latest one when its non-stacking deadline expires; timers, renewal, and pellet replacement continue while that snake is frozen. New pellets grow from a point to their full size. An eaten pellet shrinks while moving into the eater's circle center; reduced-motion preferences show the resulting state immediately. The server then tries to restore the configured number of that pellet type. If multiple snakes reach the same pellet in one update, the earliest contact wins. An exact tie uses room order, with human players before the bot. Total pellets eaten counts both types and is tracked separately from the scores.

On every selected penalty-renewal interval, the game chooses one current red penalty pellet at random, removes it, and uses the same replacement flow to create a fresh penalty pellet at a random valid location. If a real snake collision occurs at that exact deadline, the collision resolves first. A timed renewal does not change any score, Total pellets eaten, end-condition progress, pellet-consumption history, or the no-pellet timeout, and it has no eater-collapse animation.

Circle player control

Move a mouse pointer or tap once with touch or pen inside the arena to select an exact destination, shown as an ×. You can instead move a mouse pointer or tap once within the direction movement circle in the bottom-right corner. The direction from its center to the pointer guides your snake toward a movement destination on its legal boundary. Touch and pen movement after the initial press does not send another command. The arrow marker points that way but stays no farther than 33% of the gameplay radius from your snake, while the movement destination remains at the boundary. The latest update from either region continuously replaces the previous destination. The first destination starts immediately; while your snake is moving, later updates automatically steer toward the newest destination over a short three-tick curve so delayed input does not create sharp zigzags. The snake stops if it reaches that destination before the pointer moves again, and every destination remains inside the legal center circle. For arena movement, the direction-circle arrow points from the snake toward the exact destination and disappears when it is within 0.1 game unit of the snake center.

Sphere steering and searching

In Sphere, movement is continuous, starting during the countdown. Move the mouse or tap once with touch or pen inside the arena or direction circle to change direction. The snake keeps that direction along a great circle until you steer again. A freeze pauses movement, but steering still works and the latest direction resumes afterward.

The Sphere bot considers only rewards and penalties in its current visible surface. It applies the same reward lookahead as Circle, using surface distances and spherical routes. If all visible rewards are blocked, it chases the nearest directly. With no visible reward, it chooses a random direction and follows that great circle for at least twice the gameplay sphere radius (2M), then chooses again. A reward entering view immediately interrupts this search. A freeze pauses distance travelled. During the pellet-free countdown, the Sphere bot searches too.

In every gameplay area, the bot looks ahead through up to seven visible rewards, favoring routes that collect more pellets sooner. For similarly compact clusters at equal distance, it favors five pellets over two. It counts rewards encountered along a route only once and follows the first selected leg, then reassesses as the board changes. It compares its cumulative planned time to first reward contact with each visible active opponent's fastest direct arrival, using their speeds and any remaining movement freeze. Its own route includes penalty detours; opponents are assumed willing to race directly and may ignore penalties. It counts a reward only if it can arrive strictly before every visible opponent, so ties are contested. If every immediate visible reward is contested, it uses the same lookahead strategy without considering opponents.

Bot, scoring, and results

Every human snake moves at the configured human speed, while the optional radius-1 bot moves at its own configured speed. In Circle, after the countdown, the bot continually chooses the first reward on its highest-scoring lookahead route. It moves straight toward that reward when the route is clear; otherwise, it takes the shortest available left-or-right route around the penalty pellets while staying inside the game area. Unsafe routes are skipped while an eligible reward has a safe route. If no eligible reward has a safe route, the bot moves straight toward the nearest reward and may eat penalty pellets along the way. After those collisions change the board, it returns to a safe route as soon as one is available; the Circle bot waits only when no reward pellet exists. The semantic Player/Score scoreboard table uses shared center-start and center-end column alignment and tracks every human and all bots, while Total pellets eaten counts every reward and penalty pellet consumed. Player cards are shown only while the room is waiting; during gameplay and after the game ends, the scoreboard is the participant list. A separate information box directly below the Scores box contains Elapsed time, Total pellets eaten, and Progress so the circular game area can use the space above. Progress shows the rounded percentage of elapsed time, combined pellets eaten, or the leading score toward the selected end condition. A game stops when the selected pellet total is reached, its server wall-clock time deadline expires, any human or bot reaches the selected point target, no reward or penalty pellet has been eaten for the selected inactivity duration, or every player has resigned. Results rank higher scores first, and equal scores share a placement.

When a rated registered multiplayer room reaches its time, pellet, point-target, or no-pellet inactivity limit naturally, every human in the final roster receives an ELO result, including anyone who resigned earlier. A participant's player score is their final score divided by the sum of all final scores. If every score is zero, everyone instead receives 1 / participant count. Both bots, when present, are included in that count and in the normal expected-score calculation at fixed ELO 1500 each.

The bots' combined hypothetical ELO change is shared equally among the humans, while each bot remains at 1500 with a change of 0. Human ELO changes always total 0, and no rating may fall below 1. A glowing podium appears immediately beside Scores while Info counts down three seconds. Selecting the enabled podium opens the table early and clears Info; otherwise it opens automatically at the deadline when the final calculation is ready. The table shows ranking, status, score, ELO change, and new ELO. Close keeps the completed room open, and Exit returns to the lobby. Rated registered-human ELO changes and new ratings use exactly one decimal place. Increases are green, decreases are red, and unchanged changes are white. Guest and bot rows show dashes in both ELO columns.

Leaving and reconnecting

A disconnected snake continues to its last destination and then stops, so its player may reconnect. During active play, the departure control shows Resign. Its confirmation offers Resign to remain and watch or Resign & Exit to return to the lobby after the same resignation succeeds. Both remove that snake from active play while preserving its score and roster entry; when the player remains, the same navbar control changes to Exit and the remaining players continue. A direct active Exit request has the same resignation result; top-left navigation and closing the page only change presence. Without a bot, the room is abandoned when every human has resigned. The bot never resigns, so a bot-enabled room continues after every human resigns until its selected time, pellet, point-target, or no-pellet inactivity limit is reached. Current and recently ended rooms are retained only in the server's temporary room archive. An abandoned room does not update ELO. Naturally completed registered rooms update current ELO and its timestamped history, but Snake does not store a permanent full-game result record.