Roblox工作室 MCP
让一个AI代理驱动Roblox Studio:读取您的位置,编辑脚本,构建几何,运行播放测试,取取取截图. 35个工具.

安装
在Windows(x64,ARM)和macOS(苹果硅,英特尔)上运行. 服务器是 npm 为您的平台选择的本地二进制; npx 需要节点18或更新.
1. 插件
npx -y @el4cteo/rbx-studio-mcp --install-plugin
或者掉下来 StudioMCP.rbxmx 从 释放 输入工作室插件文件夹.
2. 服务器
claude mcp add rbx-studio -- npx -y @el4cteo/rbx-studio-mcp
其他客户
代码 CLI :
codex mcp add rbx-studio -- npx -y @el4cteo/rbx-studio-mcp
Cursor,克洛德桌面,双子座CLI,Windsurf:
{
"mcpServers": {
"rbx-studio": {
"command": "npx",
"args": ["-y", "@el4cteo/rbx-studio-mcp"]
}
}
}
VS 代码 / 副驾驶 (.vscode/mcp.json) 用途 "servers" 改为 "mcpServers"附加时 "type": "stdio"。 。 。 .
打开代码( o)opencode.json:
{
"mcp": {
"rbx-studio": {
"type": "local",
"command": ["npx", "-y", "@el4cteo/rbx-studio-mcp"],
"enabled": true
}
}
}
深搜索机:见 config/dsh.cordis.yml需求 DEEPSEEK_API_KEY。 。 。 .
3个. 打开工作室并接受 127.0.0.1 快点 检查它的工作 studio_status。 。 。 .
有什么不对吗? 运行 npx -y @el4cteo/rbx-studio-mcp doctor上面写着什么是破碎的以及如何修复的.
端口为 44755 (英语)。用 --port 并匹配插件中的内容.
工具
| 会议 | studio_status list_studios set_active_studio |
| 发现 | tree inspect find api |
| 脚本 | script_read script_edit script_grep script_create sync |
| 实例 | create modify delete move |
| 世界 | geometry terrain generate assets collision audio undo |
| 数据直播游戏( L) | datastore universe |
| 运行调试( D) | playtest execute_luau character input console debug performance |
| 听着 | screenshot viewport device |
写入工具需要数组: 十个脚本编辑为一调和一个 缩写+Z,而要么全部适用,要么没有.
device 模拟一直持续到 device op="stop"。 。 。 .
为什么这个
- 快速 : 桥上用电话而不是投票,每通电话13.6毫秒对25.8毫秒.
- 安全脚本编辑 : 写作通过脚本编辑器,所以未保存的工作能活下来.
- Stale 编辑被拒绝 : 线程和整个文件编辑需要
rev从script_read。 。 。 . - 检查财产名称 对运行的引擎,所以
Anchorred回来作为建议,而不是运行时间错误.
调试播放测试
播放器连接第二个会话,所以通过它 studioId。使用编辑会话进行必须持久的修改.
读者可以在玩家自己的客户端中运行 target="client" (编) player="Name" 有多个玩家:
tree target="client" path="Players.Alice.PlayerGui" handles=true
find target="client" className="TextButton"
viewport op="pick" x=0.5 y=0.5 target="client"
debug op="watch" path=... target="client" properties=["Text"] seconds=5
- 处理 (单位:千美元)
handles=true替换路径。 它们在重命名和移动后幸存下来,一旦对象被删除或过期就会失败. viewport op="uisnap"截取一个UI。 再来一次compareTo="<id>"看看有什么变化.debug op="collisions"报告什么是部分或模型打击, 最困难的第一.performance op="microprofile"排列填充您帧的引擎瞄准镜 。 使用罗布洛克斯的 自由软件 (麻省理工学院).collision op="cast"扫射射出射线 地块 球体 或真正的部分.- 剪辑
execute_luau结果 返回 aresultId。通过它120秒而不重跑.
文档工作
sync 将您的脚本映射到文件夹中,因此代理可以使用自己的文件工具编辑代码并使用 Studio进行测试.
sync op="pull" # Studio -> ./studio
sync op="push" # ./studio -> Studio
sync op="watch" # both ways, live, until op="stop"
- 布局 : 罗乔式( Rojo- system) :
Main.server.luau, (中文(简体) ),.client.luau, (中文(简体) ),.luau页:1sourcemap.json为卢斯普. - 重命名数 : 重命名或移动文件,脚本随它移动.
- 冲突: 两边的编辑都意味着两者都不被触碰。 工作室的版本等待在
.rbx-sync/conflicts/合并并同步,或通过prefer: "studio"或者说"disk"。 。 。 . - 删除: 删除文件删除脚本(1 Ctrl+Z). 工作室删除的脚本将其文件发送给
.rbx-sync/trash。 。 。 . - 作为文件的 UI :
export将实例树写为.build.json文档,以及build重建它 重建它 重建它.
打开云
有些电话通过工作室到达Roblox本身,需要API密钥. 其它一切皆无一相能行.
assets op="upload" | 发送本地音频、图像、模型或视频文件,获取资产编号 |
datastore target="live" | 运行中的游戏真实玩家数据 |
execute_luau target="live" | 在发布的地方运行脚本 |
universe | 重新启动服务器、信件、禁止玩家、阅读日志和分析、销售产品和通行证、安排活动 |
| (单位:千美元) | assets op="grant", (中文(简体) ), op="publish", (中文(简体) ), script_read编号 :script_edit target="live" |
制作一个键在 创建者 Dashboard – 证书,然后在工作室面板上:
cloud key <paste>
cloud user <your user id>
cloud place <place id>
密钥权限
添加你想要的内容 : assets, (中文(简体) ), universe-datastores, (中文(简体) ), ordered-data-stores, (中文(简体) ), luau-execution-sessions, (中文(简体) ), universe-places, (中文(简体) ), universe-place-instances, (中文(简体) ), universe, (中文(简体) ), messaging-service, (中文(简体) ), user-restrictions, (中文(简体) ), inventory, (中文(简体) ), users, (中文(简体) ), asset-permissions, (中文(简体) ), developer-products, (中文(简体) ), game-passes, (中文(简体) ), universe-analytics2. 时间安排需求 universe.event:read 财务报告和审定财务报表 :write。 。 。 .
密钥存储于 ~/.rbx-studio-mcp/credentials.json从不在文件 或谈话. cloud 显示设置, cloud test 重新检查它, cloud forget 删除它. ROBLOX_API_KEY 环境的朋友优先.
每场比赛权限. 代理只能读取游戏的设置,直到您允许更多. 类型 allow 在显示开放游戏列表的面板中, allow <group> 打开一个, allow <group> off 把它关掉。 组 : read, (中文(简体) ), assets, (中文(简体) ), data, (中文(简体) ), edit (设置、出版、重新启动、直播Luau), money (产品和通行证), players (bans) (英语).
控制台面板
每通电话都被记录了多久 面板脚下是命令行:单击它可以看到每个命令,或键入 help。 。 。 .
有动画背景的六个主题:"星云","恩伯","潮","银河","奥罗拉"和"摩诺利". 从头部的点上选一个,或者用 theme <name>· ; background off 把动画关掉.
运行 chat on 您输入的句子会输入一个真正的编码代理 。 它在你的PATH上使用任何31个支持的特工,比如克洛德密码,Codex或双子座; agent 列出他们和 agent use <id> 选一. 它与您的终端分开运行 并且单独收费。 克劳德代码和副驾驶仅限于 rbx-studio 工具;其他工具使用自己的权限设置。 这个 停下来 按钮取消.
运行 playpanel on 也可以在播放测试时显示面板(默认关闭). playpanel left, (中文(简体) ), right 或者说 bottom 把它停在那里; playpanel float 以面板大小浮动.
警卫
服务器只听回回放 。 请求需要一个浏览器无法设置交叉源代码和回路的页眉 Host,所以一个网页无法到达,即使通过DNS重新绑定. 你的经验是"Allow HTTP Request"的设定没有改变.
发展
服务器是 Rust (server/,工具链被绑到1.991;插件是Luau(plugin/) (中文(简体) ).
cargo build --release --manifest-path server/Cargo.toml
node scripts/install-plugin.mjs # build the plugin and copy it into Studio
cargo test --manifest-path server/Cargo.toml
node scripts/test-native.mjs # black-box MCP and bridge tests
插件检查需要 luau, (中文(简体) ), luau-compile 财务报告和审定财务报表 luau-analyze 从 卢奥的释放 打开 PATH 或进入 tools/。 。 。 .
现场测试需要使用加载的插件打开 Studio,然后自己清理: scripts/test-live.mjs, (中文(简体) ), test-live-tools.mjs [--playtest], (中文(简体) ), test-live-sync.mjs 财务报告和审定财务报表 test-live-sync-scale.mjs。 。 。 .
喊叫声
感谢 GameDev 工具 在Roblox Studio的免费AI工具中.
许可证
麻省理工学院.