关于 MCP Game Helper
MCP Game Helper 是面向游戏开发者的 MCP 服务,提供战斗与技能分析、关卡节奏、模拟及代码性能反馈工具。它还可根据自然语言描述建议敌方 AI 状态机。
主要功能
- 01评估战斗平衡
- 02模拟战斗与房间生存
- 03分析技能影响
- 04检查难度进程与波次间隔
- 05建议 AI 状态机并分析代码性能
适用场景
- 01比较玩家与敌人的战斗属性
- 02估算生存时间和清房时间
- 03评估技能对敌方生命值的效果
- 04调整关卡难度和敌人波次
MCP 相关
它向 MCP 客户端提供游戏开发分析与模拟工具,并支持与 Cursor 集成。
配置
本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。
工具
还没有获取到工具列表
本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。
详细介绍
MCP Game Helper
MCP Game Helper 是一个自定义的模型上下文协议(MCP)服务,提供 AI 驱动的工具,帮助游戏开发者完成战斗平衡、技能分析、关卡节奏和模拟相关任务。
专为与 Cursor 集成而构建,使用官方
@modelcontextprotocol/sdk
🚀 可用命令
1. suggest_balancing
分析两个实体的生命值和伤害,以评估对战是否平衡。
输入示例:
{
"player": { "hp": 2040, "damage": 1500 },
"enemy": { "hp": 2080, "damage": 1000 }
}
提示词示例:
I want to check if my player and enemy are balanced.
Player: 2040 HP, 1500 DMG
Enemy: 2080 HP, 1000 DMG
2. simulate_combat
模拟战斗场景,并估算两个实体各自击杀对方所需的时间(TTK)。
输入示例:
{
"player": { "hp": 100, "damage": 10, "attackSpeed": 1.0 },
"enemy": { "hp": 80, "damage": 20, "attackSpeed": 0.5 }
}
提示词示例:
Simulate a fight:
Player has 100 HP, 10 DMG, 1.0 attack speed
Enemy has 80 HP, 20 DMG, 0.5 attack speed
3. simulate_room_survival_time
估算玩家在多个敌人的攻击下能够存活多久,以及清空房间所需的时间。
输入示例:
{
"player": { "hp": 100, "damage": 15, "attackSpeed": 1.2 },
"enemies": [
{ "hp": 40, "damage": 10, "attackSpeed": 0.8 },
{ "hp": 50, "damage": 12, "attackSpeed": 1.0 }
]
}
提示词示例:
How long will my player survive in a room?
Player: 100 HP, 15 damage, 1.2 speed
Enemies: One with 40 HP, 10 damage, 0.8 speed, another with 50 HP, 12 damage, 1.0 speed
4. simulate_skill_impact
根据技能的伤害、作用范围和冷却时间,模拟技能的效果。
输入示例:
{
"skill": {
"damage": 80,
"cooldown": 5,
"area": 3
},
"enemies": [{ "hp": 100 }, { "hp": 80 }, { "hp": 60 }]
}
提示词示例:
My skill deals 80 damage, has 5s cooldown, and hits 3 enemies.
Enemy HPs: 100, 80, 60
How good is this skill?
5. suggest_difficulty_ramp
分析关卡之间的进度变化,并反馈难度提升是平缓还是陡峭。
输入示例:
{
"levels": [
{ "name": "Forest", "enemyHp": 50 },
{ "name": "Cave", "enemyHp": 80 },
{ "name": "Castle", "enemyHp": 120 }
],
"player": { "damage": 25, "attackSpeed": 1.0 }
}
提示词示例:
My player deals 25 dmg/sec.
Forest enemies: 50 HP
Cave: 80 HP
Castle: 120 HP
Is this difficulty curve balanced?
6. predict_performance_impact
扫描代码片段,并反馈可能存在的性能问题。
输入示例:
{
"code": "for (let i = 0; i < 10000; i++) { this.spawnEnemy(); }"
}
提示词示例:
Can you check this code for performance issues?
for (let i = 0; i < 10000; i++) {
this.spawnEnemy();
}
Also, I sometimes use setInterval inside update(). Is that bad?
7. suggest_ai_state_machine
根据自然语言描述的行为,生成 AI 状态机建议。
输入示例:
{
"description": "This enemy walks around the map until it sees the player, then it chases them. If close enough, it attacks. If it loses sight, it goes back to patrolling."
}
提示词示例:
This enemy walks around the map until it sees the player, then it chases them.
If close enough, it attacks. If it loses sight, it goes back to patrolling.
Can you suggest a state machine?
8. suggest_wave_timing
根据玩家的 DPS 和敌人的生命值,建议敌人波次之间的理想间隔时间。
输入示例:
{
"player": { "damage": 30, "attackSpeed": 2 },
"enemyHp": 100,
"enemiesPerWave": 3
}
提示词示例:
My player deals 30 damage per hit and attacks twice per second.
Each enemy has 100 HP, and I spawn 3 enemies per wave.
What should be the ideal time between waves?
🛠 如何在本地运行
- 安装依赖:
npm install
- 构建项目:
npm run build
- 全局安装软件包:
npm install -g .
- 确保在
.cursor-config.json中注册该服务:
{
"mcpServers": {
"mcp-game-helper": {
"command": "npx",
"args": ["-y", "mcp-game-helper"]
}
}
}
💡 参与贡献
欢迎为游戏开发者提出新的实用命令,尤其是专注于 AI、平衡和模拟的命令!
📘 许可证
MIT
评论
支持 Markdown
一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。