setup-multiplayer

Adds multiplayer networking to existing games using MultiplayerAPI, MultiplayerSpawner, and MultiplayerSynchronizer.

66|4|Updated Feb 26, 2026
One-click install
npx skills add https://github.com/SummerEngine/summer --skill setup-multiplayer-summerengine
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: setup-multiplayer
Source: https://github.com/SummerEngine/summer/tree/main/library/skills/setup-multiplayer
Command: npx skills add https://github.com/SummerEngine/summer --skill setup-multiplayer-summerengine

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Retrofitting multiplayer onto an existing single-player game is architecturally risky: choosing the wrong authority model or replication strategy forces expensive rewrites later. This Skill guides the irreversible decisions first, then implements LAN/online co-op, PvP, or lobby-based multiplayer using Summer Engine's high-level networking stack. ## Core Features & Use Cases - Authority Model Selection: Walks through four blocking questions (game type, player count, simulation owner, network target) and locks host authority, dedicated server, or peer-to-peer before any code is written. - Network Autoload & Spawning: Generates a Network autoload with ENetMultiplayerPeer host/join logic and converts static player nodes into MultiplayerSpawner-managed per-peer instances. - Replication & RPC Patterns: Configures MultiplayerSynchronizer for position, rotation, and health, and applies the four RPC conventions with mandatory sender validation via get_remote_sender_id(). - Use Case: You have a working single-player co-op shooter and want 2-4 player online co-op. The Skill proposes the change set, builds the autoload, player scene synchronizer, and host/join UI, then verifies with a two-instance playtest. ## Quick Start Add multiplayer to my game so two players can host and join a co-op session over LAN.

Frequently Asked Questions about setup-multiplayer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add multiplayer to an existing single-player game?

Start by locking the authority model before writing code: host authority for 2-4 player co-op, dedicated server for competitive PvP. Then add a Network autoload for peer setup, convert the player into a MultiplayerSpawner-managed instance, and replicate only position, rotation, and health via MultiplayerSynchronizer.

What is the difference between host authority and dedicated server authority?

Host authority lets one player run the simulation, which is cheapest and suits 2-4 player co-op but gives the host a latency advantage. Dedicated server authority is fair and supports anti-cheat for competitive PvP, but requires server hosting and a deploy story.

Should I use ENet or WebSocket for multiplayer networking?

Use ENetMultiplayerPeer by default; it provides UDP with reliability layers and ships with the engine. Switch to WebSocketMultiplayerPeer only for HTML5 browser exports, since ENet does not work in browsers, or WebRTCMultiplayerPeer for browser P2P.

Why does my multiplayer game spawn duplicate players on every peer?

Duplicate players happen when every peer spawns its own copy instead of using MultiplayerSpawner. Only the host should spawn players; clients receive instances automatically through the spawner, with each player named by its peer ID.

How do I prevent cheating in any_peer RPC calls?

Validate multiplayer.get_remote_sender_id() inside every any_peer RPC and confirm the sender matches the node's multiplayer authority before acting. For damage handlers, also gate execution with multiplayer.is_server() so only the host applies state changes.

When should I avoid rollback netcode or host migration?

Rollback netcode suits fighting games and lock-step RTS titles, not co-op shooters, and is a large standalone project. Host migration is a feature, not a primitive; ship v1 without it and add it later only if churn data demands it.