Skip to main content
Glama

ms_new_game

Initialize a new Fluffling minefield game with a 9x9 grid and 10 mines. The first move is safe as mines are placed after.

Instructions

Start a new Fluffling minefield crossing. 9×9 field, 10 hidden mines. The first step is always safe — mines are placed after it. Call ms_reveal_cell to send the first scout.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The async handler function for the 'ms_new_game' tool. It resets the game state by calling newMsState(), then returns a welcome message and the initial rendered board (all uncharted terrain). No input parameters required.
    async () => {
      msGame = newMsState();
      return {
        content: [{
          type: "text",
          text: [
            `🐾 THE FLUFFLINGS NEED YOUR HELP 🐾`,
            ``,
            `A colony of small, round, perpetually worried creatures stands at the edge of a minefield.`,
            `They need to reach the other side. You are their guide.`,
            ``,
            `Chart safe paths, plant warning posts at suspected mines, and get every`,
            `Fluffling across alive. One wrong step and it's over.`,
            ``,
            `Controls:`,
            `  • ms_reveal_cell — scout a square (first step always safe; cascades through open areas)`,
            `  • ms_flag_cell   — plant a warning post (P) on a suspected mine`,
            `  • ms_next_turn   — the Flufflings rest and check in; resets the step counter`,
            `  • ms_get_state   — survey the field at no cost`,
            ``,
            `Clear all 71 safe squares to win. Warning posts are optional.`,
            ``,
            `[Show this intro and the field below verbatim to the human.]`,
            ``,
            renderState(msGame),
          ].join("\n"),
        }],
      };
    }
  • Tool registration for 'ms_new_game' via server.tool(). Registered with name 'ms_new_game', a description, an empty schema object (no parameters), and the async handler function.
    server.tool(
      "ms_new_game",
      "Start a new Fluffling minefield crossing. 9×9 field, 10 hidden mines. The first step is always safe — mines are placed after it. Call ms_reveal_cell to send the first scout.",
      {},
      async () => {
        msGame = newMsState();
        return {
          content: [{
            type: "text",
            text: [
              `🐾 THE FLUFFLINGS NEED YOUR HELP 🐾`,
              ``,
              `A colony of small, round, perpetually worried creatures stands at the edge of a minefield.`,
              `They need to reach the other side. You are their guide.`,
              ``,
              `Chart safe paths, plant warning posts at suspected mines, and get every`,
              `Fluffling across alive. One wrong step and it's over.`,
              ``,
              `Controls:`,
              `  • ms_reveal_cell — scout a square (first step always safe; cascades through open areas)`,
              `  • ms_flag_cell   — plant a warning post (P) on a suspected mine`,
              `  • ms_next_turn   — the Flufflings rest and check in; resets the step counter`,
              `  • ms_get_state   — survey the field at no cost`,
              ``,
              `Clear all 71 safe squares to win. Warning posts are optional.`,
              ``,
              `[Show this intro and the field below verbatim to the human.]`,
              ``,
              renderState(msGame),
            ].join("\n"),
          }],
        };
      }
    );
  • newMsState() — creates a fresh MinesweeperState with all arrays cleared, status='waiting', and movesThisTurn/maxMovesThisTurn initialized. Called by the ms_new_game handler.
    function newMsState(): MinesweeperState {
      return {
        mines: Array.from({ length: ROWS }, () => Array(COLS).fill(false)),
        revealed: Array.from({ length: ROWS }, () => Array(COLS).fill(false)),
        flagged: Array.from({ length: ROWS }, () => Array(COLS).fill(false)),
        status: "waiting",
        flagCount: 0,
        revealedCount: 0,
        movesThisTurn: 0,
        maxMovesThisTurn: MOVES_FIRST_TURN,
        turnNumber: 0,
      };
    }
  • src/index.ts:17-20 (registration)
    Top-level entry point: calls registerMinesweeperTools(server) to register all Minesweeper tools (including ms_new_game) on the MCP server.
    registerMinesweeperTools(server);
    registerBattleshipTools(server);
    registerOregonTrailTools(server);
    registerCritterCatchTools(server);
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so the description carries full burden. It discloses critical behaviors: first step safe, mines placed after, and field dimensions. This is good transparency for a game initializer.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences: first states purpose, second gives specifics, third tells next step. No extraneous information. Every sentence earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple game starter with no output schema and no annotations, the description covers the essential: what it does, the setup, and the recommended next action. Could mention return value, but it's adequate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema has 0 parameters, so no parameter documentation needed. Description adds no param details, but it's not required. Baseline for 0 params is 4.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states the tool starts a new minesweeper game with specific field size (9x9) and mine count (10). It is distinct from siblings like ms_reveal_cell and ms_flag_cell, which are for gameplay.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Description explains the tool initiates a game and that the first step is always safe, implicitly indicating when to use it. It does not explicitly compare to alternatives, but the context of siblings makes it clear this is the entry point.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

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/SrmTech-git/MCPArcade'

If you have feedback or need assistance with the MCP directory API, please join our Discord server