end_combat
End the current combat encounter on the D&D MCP Server with a single command. Quickly resolve battles, reset game states, and streamline campaign sessions for efficient gameplay.
Instructions
End the current combat encounter.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/gamemaster_mcp/main.py:636-644 (handler)The main handler function for the 'end_combat' tool. It is decorated with @mcp.tool for registration and directly implements the logic to end combat by updating the game state: setting in_combat to False, clearing the initiative order, and resetting the current turn.@mcp.tool def end_combat() -> str: """End the current combat encounter.""" storage.update_game_state( in_combat=False, initiative_order=[], current_turn=None ) return "Combat ended."