fmod-mcp
fmod-mcp
一个 MCP 服务器,允许 AI 编码代理通过 TCP(端口 3663)与 Studio 内置的 JavaScript 脚本终端通信,从而驱动 FMOD Studio —— 包括导入音频、创建事件、连接乐器和构建库。
专为 Claude Code 构建,但也适用于任何兼容 MCP 的客户端。
要求
FMOD Studio 2.02+(脚本终端在近期的版本中一直很稳定)
Python 3.11+
运行中的 FMOD Studio 实例,并打开了目标项目
安装
git clone https://github.com/jmperez127/fmod-mcp.git
cd fmod-mcp
python3 -m venv .venv
source .venv/bin/activate
pip install -e .在 Claude Code 中注册
在克隆的 fmod-mcp 目录内运行此命令(以便 $(pwd) 正确解析):
claude mcp add fmod -s user -- "$(pwd)/.venv/bin/python" -m fmod_mcp-- 用于结束 claude mcp add 的标志解析,因此 -m fmod_mcp 会被视为 Python 的参数。-s user 会为机器上的每个 Claude Code 会话注册该服务器;如果需要项目本地注册,请去掉该参数。
或者,如果您更喜欢全局可调用的 shim,可以通过 pipx 安装:
pipx install .
claude mcp add fmod -s user fmod-mcp验证:
claude mcp list配置主机/端口(可选)
默认为 127.0.0.1:3663。可以通过环境变量覆盖:
export FMOD_MCP_HOST=127.0.0.1
export FMOD_MCP_PORT=3663在 Studio 中启用 TCP 脚本
FMOD Studio 的脚本终端默认监听 TCP/3663。如果它被禁用:
打开 FMOD Studio
Edit→Preferences(macOS 上为FMOD Studio→Preferences)查找
Scripting/Terminal设置启用 TCP 监听器,并记下端口
快速冒烟测试
在 FMOD Studio 运行且打开项目的情况下:
> ping
{ ok: true, version: "2.02.24" }
> list_banks
[ { path: "bank:/Master", guid: "...", name: "Master" }, ... ]典型的端到端流程(添加一个音效)
> import_audio /absolute/path/to/my_sound.wav
{ guid: "abc...", name: "my_sound.wav", length: 0.84 }
> create_event event:/test/my_sound bank:/Master
{ guid: "def...", path: "event:/test/my_sound", bank: "bank:/Master", bus: null }
> add_single_sound event:/test/my_sound abc...
{ track_guid: "...", instrument_guid: "...", audio_file_guid: "abc...", length: 0.84 }
> save_project
{ ok: true, saved: true }
> build_banks
{ ok: true, built: true, banks: [...] }现在,新事件可以通过您使用的任何 FMOD 运行时在游戏中播放(例如 Godot 中的 FmodServer.play_one_shot("event:/test/my_sound"))。
它写入的文件
~/.cache/fmod-mcp/commands.log—— 发送到 Studio 的每个 JS 代码片段,并按请求 ID 添加了时间戳。审计跟踪 + 重放源。
当出现故障时
FMOD Studio 脚本 API 的文档记录不均衡,且某些方法/属性名称因 Studio 版本而异。如果工具失败:
检查
~/.cache/fmod-mcp/commands.log以获取发送出的确切 JS 代码将其粘贴到 Studio 自身的脚本窗口中(Studio GUI 中的
Window→Scripting)并进行迭代一旦正常工作,请修补
fmod_mcp/tools/*.py中相应的 JS 模板
对于任何命名工具未涵盖的内容,请使用 run_js:
> run_js return studio.project.model.Event.findInstances().length;
42布局
fmod_mcp/
├── studio_client.py # TCP/3663 client — single persistent connection, request sentinels
├── server.py # FastMCP tool registration, stdio transport
├── __main__.py # python -m fmod_mcp
└── tools/
├── discovery.py # ping, list_*, get_event
├── audio.py # import_audio
├── events.py # create_event, add_single_sound, set_event_property, assign_to_*
├── project.py # save_project, build_banks
└── escape.py # run_js许可证
MIT © 2026 jmperez127。
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
An MCP server that integrates with Discord to provide AI-powered features.
MCP server for Producer/Riffusion AI music generation
Hosted MCP server connecting claude.ai, ChatGPT and other AI apps to your own computer
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jmperez127/fmod-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server