Server & Client Scripting
Server-side world manipulation, entities, recipes. Client-side keyboard input, screen UI, sounds, SQLite storage, and HTTP requests.
Build custom gameplay, mini-games, and UIs — no JDK, no Java compilation required.
# In-game: create a new project
/box3script create mygame
# Build and watch
cd config/box3/script/mygame
npm install
npm run build -- --watch
# TypeScript type checking
npm run check// src/server/app.ts — your first script
world.onChat((entity, message) => {
if (message === "!hello") {
entity.player.directMessage(`Hello, ${entity.player.name}!`);
return false;
}
return true;
});| Component | Version |
|---|---|
| Minecraft | 1.21.1 |
| Mod Loader | NeoForge |
| Java | 21 |
| JS Engine | Mozilla Rhino 1.9.1 (ES5) |
| TypeScript | via Babel → ES5 |