Introduction¶
When doing Minecraft-related automation in DeepSeek Harness (DSH), common approaches are writing scripts to simulate keyboard and mouse, or starting a separate mineflayer process and letting the agent invoke it indirectly. The former easily fights for focus with DSH’s own window and screenshots end up capturing the IDE as well; the latter can play at the protocol layer, but it’s a separate path from “real PCL2 client rendering”.
dsh-mc-client is published by maintainer DRheEheAMGary, categorized as a client plugin, currently at version 1.2.0 (MIT license, requires Node.js >= 20). It unifies both routes into a single set of DSH tools: one uses Win32 to control the visible Java client launched by PCL2 under E:\Minecraft; the other launches a vanilla dedicated server in a hidden local console and plays via mineflayer protocol bot, without creating a game window, without rendering, and without injecting desktop keyboard/mouse. The headless side can also read F3-style debug info and surrounding block states.
What Is This¶
In one sentence: a Minecraft Java Edition plugin for DeepSeek Harness, exposing tools like mc_launch, mc_control, mc_headless, mc_bot for agents to launch/join servers, perform keyboard/mouse or protocol-layer operations, read back screenshots and logs, and detect blocks.
Repository: https://github.com/DRheEheAMGary/dsh-mc-client
Community directory page: https://www.skillhub.cn/plugins/DRheEheAMGary/dsh-mc-client
The maintainer’s README states: installed and activated in DSH Desktop’s desktop profile, configured as include:mc-client (your profile name may differ).
Core Features¶
Headless Play¶
The caller invokes mc_headless and mc_bot via JSON tool calls: it downloads and starts a vanilla dedicated server locally (hidden console, bound to 127.0.0.1 by default), optionally copying an existing single-player save as the server world; mc_bot connects as a real server player, with coordinates, health, inventory, etc., and can move, mine, place, attack, chat, use /commands, and pathfind (mineflayer + mineflayer-pathfinder).
To observe the world, use mc_debug (headless F3: dimension, biome, coordinates, orientation, light, time, latency, entities, etc.) and mc_blocks (looking / at / scan / find modes, returning block name, state, light, hardness, etc.).
You can also use mode: connect to connect to an existing offline-mode server instead of starting a local server.
Windowed Version (PCL2 Visible Client)¶
For scenarios where the real screen must be seen:
mc_launchreplays PCL2’sPCL/LatestLaunch.bat, or auto-joins a server withserverandwaitInGame(first tries--quickPlayMultiplayer, falls back to OCR-clicking the menu if the client ignores it).mc_controluses Win32SendInputfor keyboard/mouse, view, chat;mc_screenshotprioritizes capturing only the game window.mc_client_logreads PCL or dev clientlatest.log, supportingtail/grep.
1.2.0: Windowed Automation Reliability¶
Version 1.2.0 hardens “automation on the real client” reliability; headless tool semantics are unchanged. Key points include:
- Window identification excludes DSH, Electron, and DSH sessions whose title contains “Minecraft”; focus failure returns
code:"focus-failed", avoiding silently sending input to DSH. - Screenshots prioritize
PrintWindow, so DSH overlaid on top won’t appear in the capture; falls back to desktop crop when necessary and marksmethod:"screen-crop". mc_control {action:"chat"}can read back the latest ≤10 lines of[CHAT]fromlatest.log; commands starting with/are entered via Unicode to avoid clipboard policies swallowing the slash.mc_control {action:"state"}returnsinGame,screen, etc.; whenvisual:true, OCR parses F3 and inventory.
Installation & Activation¶
The plugin is provided as an installable bundle (package.json’s dsh.bundle + cordis.patch.yml). Given a local directory already exists, the README’s installation steps are as follows (replace desktop with your profile name):
cd E:\Github\dsh-mc-client
npm install
dsh plugin --profile desktop add "E:\Github\dsh-mc-client"
Uninstall:
dsh plugin --profile desktop remove dsh-mc-client
If you’re already in the plugin directory, you can also use dsh plugin --profile desktop add . (requires running npm install in that directory first).
Before installing, please read the repository source code and MIT license yourself; the plugin runs with the current DSH process’s permissions and involves local processes, file paths, and network downloads (such as pulling the server in headless mode), so you should assess the risks according to your environment.
Typical Usage¶
Headless: From Launch to Cleanup¶
The following commands are excerpted from the README quick start (default version example is 26.1.2):
mc_headless { "action": "start" }
Copy world from existing save (modify paths to match your machine):
mc_headless {
"action": "start",
"version": "26.1.2",
"worldSource": "E:\\Minecraft\\.minecraft\\versions\\26.1.2\\saves\\新的世界 (1)"
}
Check status and operate:
mc_bot { "action": "state" }
mc_bot { "action": "move", "keys": ["forward", "sprint"], "durationMs": 2000 }
mc_bot { "action": "chat", "text": "hello from the windowless world" }
mc_bot { "action": "command", "text": "/time set day" }
mc_debug {}
mc_blocks { "mode": "looking", "maxDistance": 8 }
Stop:
mc_headless { "action": "stop" }
Connect to existing server (without starting local server):
mc_headless {
"action": "start",
"mode": "connect",
"host": "127.0.0.1",
"port": 25565,
"version": "26.1.2"
}
Windowed Version: 1.2.0 Self-Test Sequence¶
The README provides a self-test sequence (requires the target server already running locally, example port 25566):
mc_launch {edition:"java", server:"localhost:25566", waitInGame:true, waitGameSeconds:120}
mc_control {action:"state", visual:false}
mc_control {action:"chat", text:"/time set day"}
mc_screenshot {scope:"window", savePath:"docs/self-test-window.png"}
mc_client_log {grep:"CHAT|HubSuite|ERROR", tail:50}
When structured F3/inventory info is needed, press F3 or open inventory first, then run mc_control {action:"state", visual:true}.
Tool Overview¶
| Tool | Main Purpose |
|---|---|
mc_headless |
Headless: status / start / stop, server & world copying |
mc_bot |
Headless: move, view, mine, place, chat, command, pathfind, etc. |
mc_blocks |
Headless: line-of-sight/coordinate/scan/find-by-name blocks |
mc_debug |
Headless: F3-style debug info |
mc_status |
Windowed: Java/Bedrock, PCL path, game window & foreground state |
mc_launch |
Windowed: launch PCL2 client with optional auto-join |
mc_control |
Windowed: keyboard/mouse, chat read-back, state, screenshot actions |
mc_screenshot |
Windowed: game window or full-screen capture, supports region |
mc_client_log |
Windowed: tail / grep on latest.log |
For finer 1.2.0 parameter changes, see the “Tool Parameter Quick Reference” table in the README; for complete tested outputs and limitations, see the repository’s docs/client-verification-1.2.0.md and docs/headless-verification.md.
Use Cases & Notes¶
Who It’s For
- Those who want unified Minecraft Java invocation in DSH agents: both PCL2 real client screen and keyboard/mouse, and headless, scriptable protocol bots and block detection.
- Those doing reproducible automation like server joining, chat/command read-back, game window screenshots, F3 and block state queries (README includes local test records).
Environment & Limitations
- The windowed path and examples are heavily Windows-oriented (PCL2,
E:\Minecraft, Win32 focus & screenshots); the headless version depends on local Java and server downloads, with default version per README (e.g., 26.1.2). - 1.2.0 clearly distinguishes game windows from DSH windows, but OCR server-joining, GPU refusing
PrintWindow, etc. still have documented fallbacks and limitations. - The community directory SkillHub and GitHub repository are community-maintained and have no official affiliation with DeepSeek / High-Flyer; the DSH ecosystem emphasizes “everything is a plugin”, so refer to the repository README, CHANGELOG, and license before installing.
Conclusion¶
dsh-mc-client puts “visible PCL2 client control” and “headless dedicated server + protocol bot” into a single plugin, and the current 1.2.0 further strengthens window focus, screenshots, and chat read-back, facilitating verifiable Minecraft Java automation in DSH.
- Directory page: https://www.skillhub.cn/plugins/DRheEheAMGary/dsh-mc-client
- Source code & documentation: https://github.com/DRheEheAMGary/dsh-mc-client