Skip to main content
Glama

detect-gamemode

Identify the current game mode in Minecraft to determine available actions and gameplay rules for character control.

Instructions

Detect the gamemode on game

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the 'detect-gamemode' tool. It retrieves the current bot's gamemode from `bot.game.gameMode` and returns a formatted response using `factory.createResponse`.
    async () => {
      const bot = getBot();
      return factory.createResponse(`Bot gamemode: "${bot.game.gameMode}"`);
    }
  • The registration of the 'detect-gamemode' tool using `factory.registerTool`, including name, description, empty input schema, and inline handler.
    factory.registerTool(
      "detect-gamemode",
      "Detect the gamemode on game",
      {},
      async () => {
        const bot = getBot();
        return factory.createResponse(`Bot gamemode: "${bot.game.gameMode}"`);
      }
    );
  • src/main.ts:57-57 (registration)
    Invocation of `registerGameStateTools` in the main application, which registers the 'detect-gamemode' tool among others.
    registerGameStateTools(factory, getBot);
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the action ('detect') but doesn't explain what this entails—e.g., whether it's a read-only operation, requires specific permissions, has side effects, or returns structured data. This leaves critical behavioral traits unspecified for a tool that likely queries game state.

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

Conciseness4/5

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

The description is a single, efficient sentence that directly states the tool's function. It's front-loaded with the core action ('Detect') and context ('on game'), with no wasted words. However, it could be slightly more structured by clarifying the output or usage context, but it earns high marks for brevity.

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

Completeness2/5

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

Given the tool's likely complexity (detecting game state) and lack of annotations or output schema, the description is incomplete. It doesn't explain what 'gamemode' means, how detection works, or what the return value includes. For a state-querying tool with no structured output documentation, this leaves significant gaps for an AI agent to understand its use.

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?

The input schema has 0 parameters with 100% coverage, so no parameter documentation is needed. The description appropriately doesn't discuss parameters, aligning with the schema. Baseline is 4 for zero parameters, as it avoids unnecessary details and focuses on the tool's purpose without confusion.

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

Purpose3/5

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

The description states the tool's purpose ('Detect the gamemode') and specifies the domain ('on game'), which provides basic clarity. However, it's vague about what 'detect' entails operationally and doesn't differentiate from siblings like 'get-block-info' or 'read-chat' that also retrieve game state information. It avoids tautology by not merely restating the name.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives. The description lacks context about prerequisites, timing, or comparisons to siblings like 'get-block-info' for other game state queries. It implies usage for gamemode detection but offers no explicit when/when-not instructions or named alternatives.

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/yuniko-software/minecraft-mcp-server'

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