ce-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
ce-mcp
把 Cheat Engine 7.7 的 Lua 功能接到本机 MCP 客户端。CE 内的 Lua 桥通过 Windows 命名管道 \\.\pipe\ce_mcp 接收请求;Python 服务以 stdio 向 MCP 客户端提供 33 个工具。地址、扫描结果、调试器和地址表都由 CE 管理。这个项目只在本机运行,不提供网络服务。
项目用 CE 自带的 Tutorial、gtutorial 和自写测试程序开发。使用前请确认你有权操作目标进程;run_lua、内存写入、代码注入和脚本记录会在 CE 当前附加的进程中执行。
需要什么
Windows、Git、Cheat Engine 7.7(含
celua.txt和 Lua autorun)、Python 3.12。当前依赖版本见requirements.txt。一个支持本地 stdio MCP 的客户端。下面给出 Codex 配置示例。
只有运行原生测试夹具时才需要 Visual Studio C++ 构建工具(含 x86/x64 编译器和 MASM);Mono 测试另需下载 Mono 安装包。
Related MCP server: mcp-cheatengine
三步安装
克隆仓库并安装 Python 依赖。 在 PowerShell 中进入你想存放项目的目录,然后运行:
git clone https://github.com/ferrycofc/ce-mcp.git Set-Location .\ce-mcp py -3.12 --version py -3.12 -m venv .venv .\.venv\Scripts\python.exe -m pip install -r requirements.txt如果
py -3.12提示找不到解释器,先运行py -0p查看已安装的 Python;没有 3.12 就从 Python 官网安装,再打开一个新的 PowerShell 窗口重试。如果连py命令也找不到,但已安装 Python 3.12,可用解释器的实际路径代替py -3.12:& '<Python 3.12 安装目录>\python.exe' --version & '<Python 3.12 安装目录>\python.exe' -m venv .venv确认第一条命令显示的是 3.12,再继续运行上面的
pip install命令。安装 CE 启动脚本。 把参数换成你自己的 CE 安装目录;若目录在 Program Files,PowerShell 需要相应写入权限。
先检查 CE 的
autorun文件夹:安装脚本会直接覆盖已有的ce_mcp.lua和ce_mcp_path.txt。 如果里面有你要保留的内容,先备份这两个文件。.\install.ps1 -CheatEngineDir '<你的 CE 安装目录>'安装器把
ce/autorun.lua复制成 CE 的autorun/ce_mcp.lua,并在同一目录写入只含本机仓库路径的ce_mcp_path.txt。启动 CE 时,加载器读这个文件找到仓库的ce/bridge.lua;其它 Lua 模块按自身文件位置加载。移动仓库后重新运行安装器。安装后启动 CE,Lua 桥会自动加载;已有 CE 进程要重新加载启动脚本时,可在 CE 的 Lua Engine 执行dofile([[<CE 安装目录>/autorun/ce_mcp.lua]]),前提是该进程里尚未加载桥。不改客户端配置也能验证: 保持 CE 运行,在仓库根目录的 PowerShell 中执行下面的命令。它用项目虚拟环境里的 MCP SDK 启动本地服务、列出工具数并调用
ce_status;预期显示tools: 33和 CE 版本、当前进程。如果只看到管道不可用错误,请检查 CE 是否已启动且加载了桥。@' import asyncio from pathlib import Path from mcp import ClientSession, StdioServerParameters, stdio_client async def main(): root = Path.cwd() params = StdioServerParameters( command=str(root / '.venv/Scripts/python.exe'), args=['-B', str(root / 'server/server.py')], ) async with stdio_client(params) as streams: async with ClientSession(*streams) as client: await client.initialize() tools = (await client.list_tools()).tools print('tools:', len(tools)) result = await client.call_tool('ce_status', {}) if result.is_error: raise RuntimeError(result.content[0].text) print('ce_status:', result.content[0].text) asyncio.run(main()) '@ | .\.venv\Scripts\python.exe -在本地 MCP 客户端配置 Python 服务。 Codex / ChatGPT 桌面版的用户配置文件在 Windows 上默认是
$HOME\.codex\config.toml;若设置了CODEX_HOME,则在$env:CODEX_HOME\config.toml。在该文件中加入下面的 TOML,把示例路径全部换成仓库的实际绝对路径(TOML 单引号保留 Windows 反斜杠)。也可按 官方 MCP 配置说明在桌面版设置里添加本地 STDIO 服务。[mcp_servers.cheat_engine] command = 'X:\path\to\ce-mcp\.venv\Scripts\python.exe' args = ['-B', 'X:\path\to\ce-mcp\server\server.py'] startup_timeout_sec = 30 tool_timeout_sec = 180保存配置后,在 ChatGPT 桌面版的“设置 → MCP servers”中选择 Restart;Codex IDE 扩展选择 Restart extension;Codex CLI 则结束当前会话并重新启动。在 CLI 中可用
codex mcp list查看配置,进入会话后用/mcp查看已连接的服务,再调用ce_status,应看到 CE 版本和当前附加的进程。Python 服务可以先启动,CE 未运行时会返回管道不可用错误。
ChatGPT 网页版: 当前仓库只有本地 stdio 服务,不能直接把 Python 文件或 \\.\pipe\ce_mcp 填成 ChatGPT 的 Server URL。官方的 自定义 MCP 连接使用远程 SSE/streaming HTTP URL,或者具备相应权限的 Secure MCP Tunnel。仓库尚未实现这两种部署方式,也不是已发布的 ChatGPT 插件。
工具清单(33 个)
分组 | 工具 | 用途 |
进程和内存(4) |
| 查看状态、列进程、附加、读原始字节 |
扫描和值(7) |
| 首次/后续扫描、翻页、按类型读写、添加和锁定记录 |
调试器(5) |
| 硬件断点、反汇编、NOP 与恢复 |
指针(4) |
| 指针链读写与内存区域信息 |
注入和分析(4) |
| AA 脚本、特征码、注入模板、结构对比 |
CE 扩展(4) |
| Lua、变速、DLL 注入、Mono 信息 |
地址表(5) |
| 查看/激活记录,保存或载入 |
scan_first 会替换上一轮扫描,scan_next 接着当前扫描结果筛选。指针工具的偏移输入顺序是基址到最终地址;list_table 同时返回这个顺序和 CE 界面顺序。地址表记录 ID 以当前表为准,载入 .CT 后应重新查询。load_table(..., merge=False) 替换地址表;merge=True 追加。CE 会按自身规则处理 .CT 中的表脚本。
跑测试
测试使用独立 CE 实例和仓库自带的目标程序。先从仓库根目录编译原生夹具(所有输出在 work/);vswhere 会定位 Visual Studio,不依赖固定安装路径:
.\tests\build_native_fixtures.ps1在一个 PowerShell 窗口启动独立 CE,给它指定测试管道。例如测试第七步:
$env:CE_MCP_PIPE_NAME = 'ce_mcp_step7'
Start-Process -FilePath '<CE 安装目录>\cheatengine-x86_64.exe'
.\.venv\Scripts\python.exe -B .\tests\step7_integration.py其它测试脚本位于 tests/。step5_integration.py 要求 ce_mcp_step5,step6_integration.py 和 step6_mono_integration.py 要求 ce_mcp_step6,step6_print_regression.py 要求以 ce_mcp_printfix 开头的管道;切换管道时为该测试启动另一份 CE。step2_integration.py、step3_integration.py 和 step4_integration.py 使用各自的自写目标。integration.py 会附加 CE 官方 Tutorial,默认测试流程无需运行。Mono 夹具可用 tests/build_step6_mono_fixture.ps1 另行构建,它会下载 Mono 安装包到 work/。
已知限制
仅验证了 Windows 上的 CE 7.7 和 Python 3.12。CE 的 Lua API 以安装包中的
celua.txt为准;其它版本可能有差异。一个 CE 实例同一时间只保留一轮扫描、一个硬件监视任务。硬件断点数量受 CPU/调试器限制;写入指令地址由停住位置向前解码推断,极少数不明确的指令不会被当成确定命中。
run_lua的超时可以中断 Lua 指令循环,但不能强行中断正在阻塞的 CE 原生调用。管道单条响应上限为 1 MiB。命名管道和 MCP 服务没有用户认证;仅在可信的本机环境运行,不要把管道或未加防护的桥直接暴露到公网。
save_table和load_table使用 CE 原生.CT语义;载入来自别人的表前应先检查其中的 Lua/AA 脚本。
MIT 许可证见 LICENSE。
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Security scanner for MCP servers. Detect vulnerabilities, prompt injection, and tool poisoning.
Reasoning, code, anti-deception, memory harness MCP tools. Stdio or HTTPS api.ejentum.com/mcp
MCP server for tabletopsimulator documentation, generated by doc2mcp.
MCP server for OpenAI API (chat completions, image generation, embeddings) via AceDataCloud
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI to directly control Cheat Engine for process attachment, memory scanning, reading/writing, address list management, speed hack, Lua/Auto Assembler execution, and CT file management via the MCP protocol.6MIT
- AlicenseNot gradedqualityDmaintenanceThis MCP server integrates AI assistants with Cheat Engine on Windows, providing tools for process management, memory read/write, pointer resolution, AOB scanning, speedhacking, and Lua scripting via a local TCP connection.1GPL 3.0
- AlicenseNot gradedqualityDmaintenanceMCP server for Cheat Engine 7.6 that enables AI agents to perform memory scanning, reading/writing, process manipulation, debugging, and code injection via a Lua named pipe bridge.4GPL 3.0
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to control Cheat Engine for memory reading/writing, scanning, debugging, and .NET/Mono game reverse engineering through 43 Chinese-language MCP tools, with thread-safe named-pipe communication.MIT