Godot Multiplayer
/godot-multiplayer
Networked Godot 4.7 games: ENet host and join, @rpc functions, per-node authority and state replication with spawners and synchronizers.
- 许可证
- Apache-2.0
- 出品
- GameSkill 出品
所属合集
Awesome Gamedev Agent Skills
77 portable SKILL.md skills across 12 engines (Godot, Unity, Unreal, Phaser, PixiJS, three.js, Bevy, pygame, LÖVE, Roblox, Defold, Ebitengine), with a router.
我们测过
在 Godot 4.7.2 上通过 26/26 项检查(2026-10-28):能触发、有可运行示例、有截图和自检清单、单一职责、中英文文档齐全。触发检查是把提示词和 skill 描述做匹配,不是真实 agent 运行。
测试报告这个 skill 做什么
什么时候触发
Build networked games with Godot 4.7 high-level multiplayer: set up an ENetMultiplayerPeer server/client, define RPCs with the @rpc annotation (call via rpc()/rpc_id()), set per-node multiplayer authority …
GameSkill 测过的版本
GameSkill 调优版:skill 文件取自提交 184b72be0288,按我们的 skill 流程加上可运行示例、测试报告、自检清单和中文指南。
协议:基于 gamedev-skills/awesome-gamedev-agent-skills(作者 gamedev-skills),协议 Apache-2.0。ZIP 保留协议文件(LICENSE, NOTICE),CHANGES.md 列出了 GameSkill 加的所有文件。

自检清单
- 服务器用 ENetMultiplayerPeer.create_server,客户端用 create_client,并赋给 multiplayer.multiplayer_peer / Server uses ENetMultiplayerPeer.create_server, clients use create_client, assigned to multiplayer.multiplayer_peer
- 每个玩家节点以 peer id 命名,并在 _enter_tree 里调用 set_multiplayer_authority / Each player node is named after its peer id and calls set_multiplayer_authority in _enter_tree
- 改分数、判命中等权威逻辑只在服务器执行,并检查 get_remote_sender_id() / Authoritative logic (score, hits) runs only on the server and checks get_remote_sender_id()
- 玩家和子弹由 MultiplayerSpawner 生成,状态由 MultiplayerSynchronizer 同步 / Players and projectiles are spawned by MultiplayerSpawner and synced by MultiplayerSynchronizer
- peer_disconnected 时服务器移除该玩家,所有客户端同步消失 / On peer_disconnected the server frees that player and it disappears on every client
中文指南
这个 skill 做什么
让 AI 用 Godot 4.7 的高层多人联网 API 写联网游戏:ENetMultiplayerPeer 建服务器和客户端,用 @rpc 注解定义远程调用(rpc() / rpc_id()),给每个节点设置 multiplayer authority,再用 MultiplayerSpawner 和 MultiplayerSynchronizer 同步生成和状态。
什么时候用
- 给 Godot 项目加局域网或在线多人
- 写
@rpc函数,或者想让只有服务器能改分数、判命中 - 玩家位置不同步、别的客户端看不到新生成的节点、客户端能改别人的角色
怎么装
下载本页的 ZIP,把 godot-multiplayer/ 整个文件夹放进 .claude/skills/(Claude Code)或 .agents/skills/(Codex、Cursor),重启 agent。
最小示例
ZIP 里的 gameskill/examples/ 是一个 Godot 4.7 小工程「Relay Arena」:每个玩家是一个彩色方块,可以发射「火花」。用 -- role=server port=7400 启动专用服务器,再用 -- role=client port=7400 启动几个客户端;服务器会给每个连上的玩家生成方块,分数只由服务器发放。
我们怎么测的
在本机用真实 ENet 连接(127.0.0.1)同时跑 1 个无头服务器和 4 个客户端,检查 14 项:口令认证(错误口令被拒)、玩家节点以 peer id 命名并归该 peer 所有、生成同步到所有客户端、只有 owner 能移动自己的方块、单步移动被限制在 20 像素、发射 RPC 在服务器上校验 owner 和 0.5 秒冷却、分数只接受服务器发来的奖励、各端位置一致、玩家离开后在所有端被移除;再开一个带窗口的 OpenGL 客户端截图。结果在 gameskill/test-report.json。
搭配
godot-nodes-scenes:场景和节点结构input-systems:本地输入处理,再交给 RPCsave-systems:服务器端存档
安装
告诉你的 AI
Install the skill from https://gameskill.dev/skills/godot-multiplayer/install.md
GameSkill 测过的版本
mkdir -p .claude/skills
curl -fsSL https://gameskill.dev/dl/skills/godot-multiplayer.zip -o /tmp/gameskill-godot-multiplayer.zip
unzip -oq /tmp/gameskill-godot-multiplayer.zip -d .claude/skills
rm /tmp/gameskill-godot-multiplayer.zip包含内容
- Worked steps: Host or join; RPCs: client sends input to the server; Per-node authority; MultiplayerSynchronizer config
- A pitfalls section with the mistakes to avoid
- Bundled 1 reference doc the agent reads when needed
- Written for Godot 4.7
适合
- Adding multiplayer/networking to a Godot project, writing @rpc functions
- Syncing player/world state across peers
试试这条提示词
Add host and join multiplayer with ENet, RPCs and synchronised player positions.关于这个 Skill
Build networked games with Godot 4.7 high-level multiplayer: set up an ENetMultiplayerPeer server/client, define RPCs with the @rpc annotation (call via rpc()/rpc_id()), set per-node multiplayer authority, and replicate state with MultiplayerSpawner and MultiplayerSynchronizer. Use when adding multiplayer/networking to a Godot project, writing @rpc functions, or syncing player/world state across peers.
From the godot-multiplayer SKILL.md in gamedev-skills/awesome-gamedev-agent-skills.
What's inside
- Host or join (ENet)
- RPCs: client sends input to the server (any_peer, call_local)
- Per-node authority (each player controls their own avatar)
- MultiplayerSynchronizer config (editor + replication)
环境要求
- Godot 4.7
常见问题
肉鸽构筑白标起步工程(Godot 4 + Web + 平衡表)
告别空工程从零搭架子!开箱即玩的白标肉鸽构筑商业起步模板(Godot 4 完整工程 + Web 可玩版):含开局三槽赐福、无交叉 DAG 地图、扇形出牌、Boss 半血锁血、篝火/商店删牌、32 位校验防坏档 SaveStore、中英切换、30 牌/18 遗物/15 怪平衡表与 1,000 局 HTML 压测工具。
- 完整 Godot 4.3+ 工程(打开即 F5 运行,内置防坏档原子 SaveStore + 中英实时切换 LocService)
- 零构建 Web HTML5 可玩起步版(扇形手牌、2 帧受击闪白、震屏与 Boss 半血锁血全跑通)
基于 gamedev-skills/awesome-gamedev-agent-skills (作者 gamedev-skills,协议 Apache-2.0)。ZIP 里保留原作者的 LICENSE 和 NOTICE,ATTRIBUTION.md 和 CHANGES.md 写明来源提交和 GameSkill 加的内容。
搭配使用
作者标注的相关 Skills,或更适合相邻任务的 Skills。
Godot Nodes & Scenes
Structure Godot 4.7 projects: reusable scenes, runtime instancing, safe node access and autoload singletons.
Godot Signals & Groups
Decoupled Godot 4.7 gameplay with signals and groups: custom signals, Callable connections and broadcasts with call_group.
Godot Export
Export Godot 4.7 games for desktop, web and mobile: export presets, headless CLI builds for CI, web COOP/COEP and server builds.
Awesome Gamedev Agent Skills 中的更多 Skills
查看全部 45 个2D Platformer
Build a 2D platformer: run/jump control with coyote time, jump buffering, and variable jump height, plus tiled levels and hazards.
Behavior Trees & Utility AI
Build a behavior-tree runtime and a Utility AI system with response curves, plus hybrid agents where the behavior tree drives utility scoring.
Bevy ECS
Structure a Bevy app around ECS: plugins, components and resources, systems with Query and Commands, system ordering and Time.
Card Game
Build a card game: card data, deck/hand/discard zones, draw/shuffle/reshuffle, a turn structure, costs, and effect resolution.
相似 skills
Claude Code Game Studios
Turns Claude Code into a full game studio: 49 agents and 72 workflow skills arranged like a real studio hierarchy.
Godogen
Autonomous game development with Claude Code and Codex. Publishes a ready game repo for Godot, Bevy, Babylon.js or three.js.
pixelfx
244 pixel-art effects written as code (fire, explosions, magic, weather, UI, pickups, critters) plus a draft, render, look, refine loop for making new ones; every effect exports a sprite sheet with Aseprite-style JSON for Godot, Unity, Phaser or any engine.
Godot AI
Production-grade MCP server and editor plugin for Godot 4.7+: 46 tools and 120+ operations for scenes, nodes, scripts, UI and more.