What's New
Fixes a critical agent workflow issue where LLM agents would repeatedly run ILSpy decompilation instead of using the pre-built Roslyn index for code lookups, wasting significant time on each query.
Problem
Agents were calling decompile_game over and over (with the same params) then grepping the output, instead of using search_game_code / get_entity_source / browse_namespace which read from the pre-built Roslyn index in milliseconds.
Fixes
- Guard on
decompile_game: Now checks if source already exists (>100 .cs files) and returns early with a message pointing to search tools. Addedforceparameter to override when actually needed (game updates) - Updated tool descriptions: All code lookup tools (
search_game_code,get_entity_source,browse_namespace,get_setup_status) now explicitly state the index is pre-built and ready, with clear "do NOT call decompile_game" guidance - Fixed misleading error message:
game_data.pyno longer directs agents to calldecompile_gamewhen indexing isn't ready — points toget_setup_statusinstead - Stronger
decompile_gamedescription: Clearly states this is only for game updates, not normal code lookups
Changed Files
sts2mcp/server.py— Tool descriptions + decompile guard with force parametersts2mcp/game_data.py— Error message fixpyproject.toml— Version bump to 3.7.0