{"library":"prismarine-web-client","title":"Prismarine Web Client","description":"Prismarine Web Client is a browser-based Minecraft client that allows users to connect to and interact with Minecraft servers directly from a web page. It leverages the `mineflayer` library for high-level bot API interactions and `prismarine-viewer` for 3D world rendering within the browser. The current stable version is 1.6.0, with releases appearing somewhat frequently, indicating active development. A key differentiator is its ability to run entirely client-side in a web browser, connecting to standard Minecraft TCP servers via an intermediary WebSocket-to-TCP proxy that is bundled and managed by the CLI tool. This package is primarily distributed as a globally installable command-line tool that serves the client application, rather than a library intended for direct `import` into other JavaScript projects for code-level integration. Developers can interact with the running client's core functionalities, such as the `bot` instance and `viewer` for debugging and custom extensions, through global `window` objects.","language":"javascript","status":"active","last_verified":"Sat Apr 25","install":{"commands":["npm install prismarine-web-client"],"cli":{"name":"prismarine-web-client","version":null}},"imports":["window.bot","window.viewer","window.debugMenu"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"npm install -g prismarine-web-client\n\n# Run the client, which starts a web server and proxy\nprismarine-web-client\n\n# Open your browser and navigate to the client. Typically:\n# http://localhost:8080\n\n// --- Interact with the client in your browser's developer console ---\n// Example: Send a chat message\n// window.bot.chat('Hello from prismarine-web-client!');\n\n// Example: Make the bot jump\n// window.bot.entity.position.y += 5;\n\n// Example: Find a diamond ore block within 256 blocks\n// const diamondOrePos = window.bot.findBlock({\n//   matching: (block) => block.name === 'diamond_ore',\n//   maxDistance: 256\n// });\n// if (diamondOrePos) {\n//   console.log('Diamond ore found at:', diamondOrePos.position);\n// } else {\n//   console.log('No diamond ore found nearby.');\n// }","lang":"javascript","description":"Demonstrates how to globally install, run, and then interact with the served Minecraft web client via browser console commands.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}