agentleFS
AIKUSANAIKUSAN/minecraft-agent-skills-bundle/.claude/skills/minecraft-bot-qa/SKILL.md

minecraft-bot-qa

Skill4 starsChanged 2 months agoMITView on GitHub

Automated QA playthroughs of a Minecraft server with bot players on both Java (Mineflayer) and Bedrock (bedrock-protocol via Geyser/Floodgate). Use for joining a dev server as a bot, walking NPC dialogue, clicking every menu and GUI button, recording structured logs, judging results with deterministic assertions plus an optional Laya second opinion, and running an offline self-test of the tooling.

  • Installs packages

The file

We split this skill into the rules it gives an agent

9 rules. About 0 are common, 2 are distinctive, and 7 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill to test a Minecraft 1.21.x server the way a player experiences it, with bots that join over the real network path, and to …

    line 10
  2. Very specific:

    All commands run from this skill directory.

    line 21
  3. Very specific:

    Every judge also works without Laya.

    line 39
  4. Very specific:

    Keep that folder and any auth-cache* folder out of Git.

    line 50
  5. Very specific:

    Use BEDROCK_AUTH=offline only on a test server with online-mode off.

    line 69
  6. Very specific:

    Put NPC spawn points in a JSON file and point QA_NPCS at it (see scripts/java/npcs.example.json).

    line 87
  7. Distinctive:

    Run bots on a development server, never on a live server with real player data.

    line 114
  8. Very specific:

    Use throwaway test accounts.

    line 115
  9. Very specific:

    Do not press destructive menu buttons.

    line 117

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Minecraft Bot QA Skill

Scope

Use this skill to test a Minecraft 1.21.x server the way a player experiences it, with bots that join over the real network path, and to judge the recorded results. It ships a Java bot kit, a Bedrock bot kit, a mock Bedrock server, deterministic judges, an optional Laya second-opinion model, and a worked example from a real quest server.

Routing Boundaries

  • Use when: the task is playing through quests or NPC dialogue with bots, clicking through chest or form menus on Java and Bedrock, checking that crossplay players see the same content, regression-testing a dev server, or judging bot logs.
  • Do not use when: the task is writing plugin code or unit tests (minecraft-plugin-dev, minecraft-testing), operating or tuning the server itself (minecraft-server-admin), Geyser/Floodgate setup and triage (minecraft-crossplay-ops), or load-testing with many bots.

Quick Start

All commands run from this skill directory. Bots need Node.js 20 or newer (Bedrock needs Node.js 24 or newer).

npm install --prefix ./scripts
node ./scripts/check-bot-setup.mjs --selftest

The self-test starts the bundled mock Bedrock server, runs the Bedrock menu bot against it, and judges the result. It expects the healthy run to pass and a deliberately broken run (unresolved %placeholders%) to fail. If both behave, the tooling works on your machine. Nothing touches a real server.

Optional second opinion from Laya:

python -m pip install -r ./scripts/requirements.txt
node ./scripts/check-bot-setup.mjs --selftest --with-laya

Every judge also works without Laya. Pass --no-laya (or set NO_LAYA=1) to skip it on purpose.

Where Output Goes

Logs, results and sign-in caches are written to QA_OUT_DIR (default ./.bot-qa in the current directory), never inside the skill folder. Point it at your project:

export QA_OUT_DIR=./qa-output

Keep that folder and any auth-cache* folder out of Git. They can hold sign-in tokens and player names.

Workflow A: Bedrock Menu Click-Through

The bot joins as a Bedrock player, runs your menu command, and presses every button of every form depth-first, reopening the menu for each press. It never presses buttons that match the destructive pattern.

export BEDROCK_HOST=dev.example.net
export BEDROCK_PORT=19132
export BEDROCK_AUTH=microsoft
export PANEL_DIR=./path/to/your/panels
export MENU_COMMAND=/menu
node ./scripts/bedrock/bedrock_ping.js
node ./scripts/bedrock/bedrock_gui.js MyBedrockTester RUN1
python ./scripts/judges/judge_bedrock.py ./qa-output/results/bedrock-RUN1.json
  • PANEL_DIR holds your CommandPanels-style YAML files. The judge compares what the bot saw against them.
  • Use BEDROCK_AUTH=offline only on a test server with online-mode off.
  • The Microsoft device code is written to logs/msa-code-bedrock.txt under QA_OUT_DIR. Open the link, enter the code, and the bot continues.
  • Details, knobs and protocol notes: references/bedrock-bots.md.

Workflow B: Java Bot Walkthrough

scripts/java/lib.js gives you connect, a structured JSON-lines event log, pathfinding, and a vanilla-accurate entity right-click. Build scenarios from it, or start with the probes.

export QA_HOST=dev.example.net
export QA_PORT=25565
export QA_AUTH=microsoft
node ./scripts/java/auth_only.js
node ./scripts/java/probe.js MyJavaTester
node ./scripts/java/explore_npc.js MyJavaTester "Example Guide" 25
  • Put NPC spawn points in a JSON file and point QA_NPCS at it (see scripts/java/npcs.example.json).
  • scripts/java/dialogue.js drives Typewriter-style chat dialogue (hotbar scroll plus jump to confirm) and strategies.js picks progressing answers with no model in the loop.
  • Details: references/java-bots.md.

Workflow C: Full Bedrock Quest Bot

scripts/bedrock/bedrock_quest.js is a thin Bedrock protocol client with a local control API and live dashboard, so an operator (or an agent) can drive a quest step by step: move, click NPCs and blocks, craft, answer forms, write books.

export BOT_NAME=QuestBot
export CTRL_PORT=8777
node ./scripts/bedrock/bedrock_quest.js

Then open http://127.0.0.1:8777/ for the timeline, or call GET /do?c=state and GET /do?c=nearby%208 from any script. The verb list and the protocol lessons behind it are in references/bedrock-bots.md.

Judging

Deterministic assertions are the ground truth: buttons match the menu files, no %placeholders%, no null or stack traces in player text, every pressed button responds. Laya adds a second opinion on text quality and on each form outcome, and it never overrides a failed assertion. Exit code 0 means the deterministic checks passed. See references/laya-judge.md to install Laya, write your own assertions, or read results.

Safety Rules

  1. Run bots on a development server, never on a live server with real player data.
  2. Use throwaway test accounts. Never commit auth-cache* folders, logs or results.
  3. Take a locked backup before any run that can write to the world or to player data, and keep a way back.
  4. Do not press destructive menu buttons; keep MENU_DESTRUCTIVE accurate for your menus.
  5. Say plainly what was and was not verified. A bot cannot confirm visuals such as holograms, particle effects or how a real Bedrock client renders a UI.

The full dev-server routine (backups, reset, throttles, operator handoffs) is in references/dev-server-workflow.md.

Worked Example

scripts/examples/quest-server/ holds the scenarios from a real Bible-themed Java and Bedrock quest server: NPC story walkers, altar and basin offerings, flying to a menorah, crafting bread, signing a prayer book, the final quiz, GUI click-throughs, and the story-specific judges. They show how to compose the core scripts and are not meant to run against other servers. Walkthrough: references/quest-server-example.md.

Troubleshooting

  • npm install fails on raknet-native: the native RakNet build needs a compiler. Run npm install --ignore-scripts --prefix ./scripts; the Bedrock kit falls back to the pure-JS backend automatically (or set BEDROCK_RAKNET=jsp-raknet).
  • Bedrock bot never spawns: check the UDP port with bedrock_ping.js, pin BEDROCK_VERSION if Geyser lags the client, and use BEDROCK_WAIT=join for mock servers.
  • Bedrock block clicks do nothing: the client must keep sending movement input. The quest bot already does; custom bots must too.
  • "You're opening panels too quickly": raise BEDROCK_PANEL_GAP_MS.
  • Java bot kicked for version: set QA_VERSION to the server version, or leave it unset to auto-detect.

Credits

This skill is built on open-source projects. It installs them as dependencies and does not copy their code.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.