Tip
- **Some settings are not reloaded because they are used before client initialization. Settings passed on the command line also override file values. ReplayCapture is not reloaded due to technical limitations.**
+ **Some settings are not reloaded because they are used before client initialization. Settings passed on the command line also override file values.**
@@ -982,7 +982,7 @@ In scripts and remote control, no slash is needed to perform the command, eg. `q
- **Description:**
- Wait X ticks (10 ticks = ~1 second. Only for scripts)
+ Wait X ticks (20 ticks = ~1 second. Only for scripts)
- **Usage:**
@@ -1363,4 +1363,3 @@ In scripts and remote control, no slash is needed to perform the command, eg. `q
-
diff --git a/tools/README.md b/tools/README.md
index 4e8153a8..4dceae9c 100644
--- a/tools/README.md
+++ b/tools/README.md
@@ -25,6 +25,8 @@ tools/decompile.sh --version 1.21.9
tools/decompile.sh --version 1.21.9 --side CLIENT
```
+If you keep server assets outside the repo, set `MCC_SERVERS=/path/to/servers` before using `tools/mcc-env.sh` or `tools/start-server.sh`.
+
The script auto-downloads `MinecraftDecompiler.jar` from GitHub releases if it doesn't exist.
### Generating server data reports
diff --git a/tools/mcc-env.sh b/tools/mcc-env.sh
index 95f8a994..b2d7610c 100644
--- a/tools/mcc-env.sh
+++ b/tools/mcc-env.sh
@@ -5,13 +5,13 @@
TOOLS_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
export MCC_REPO="$(cd "$TOOLS_DIR/.." && pwd)"
-export MCC_SERVERS="$MCC_REPO/MinecraftOfficial/downloads"
+export MCC_SERVERS="${MCC_SERVERS:-$MCC_REPO/MinecraftOfficial/downloads}"
# Helper: convert version to tmux session name (dots -> underscores)
_mc-session() { echo "mc-${1//\./_}"; }
# --- Minecraft Server Management ---
-mc-start() { "$MCC_REPO/tools/start-server.sh" "${1:-1.20.6}"; }
+mc-start() { bash "$MCC_REPO/tools/start-server.sh" "${1:-1.20.6}"; }
mc-stop() { local v="${1:-1.20.6}"; echo "stop" > "$MCC_SERVERS/$v/stdin.pipe"; }
mc-cmd() { local v="${2:-1.20.6}"; echo "$1" > "$MCC_SERVERS/$v/stdin.pipe"; }
mc-log() { local s; s=$(_mc-session "${1:-1.20.6}"); tmux capture-pane -t "$s" -p -S "-${2:-50}"; }
@@ -19,11 +19,15 @@ mc-kill() { local v="${1:-1.20.6}" s; s=$(_mc-session "$v"); tmux kill-session
mc-list() { tmux list-sessions 2>/dev/null | grep "^mc-" || echo "No running MC servers"; }
# --- RCON ---
-mc-rcon() { "$MCC_REPO/tools/mc-rcon.sh" "$@"; }
+mc-rcon() { bash "$MCC_REPO/tools/mc-rcon.sh" "$@"; }
# --- MCC Build/Run ---
mcc-build() { dotnet build "$MCC_REPO/MinecraftClient.sln" -c Release; }
-mcc-run() { cd "$MCC_REPO" && MCC_FILE_INPUT=1 dotnet run --project MinecraftClient -c Release -- CursorBot - "localhost:${1:-25565}" 2>&1; }
+mcc-run() {
+ local port="${1:-25565}"
+ shift || true
+ cd "$MCC_REPO" && MCC_FILE_INPUT=1 dotnet run --project MinecraftClient -c Release -- CursorBot - "localhost:${port}" "$@" 2>&1
+}
mcc-cmd() { echo "$1" >> "$MCC_REPO/mcc_input.txt"; }
mcc-kill() { pkill -f "MinecraftClient" 2>/dev/null && echo "MCC killed" || echo "No MCC process found"; }
mcc-reload() {
diff --git a/tools/run-creative-e2e.sh b/tools/run-creative-e2e.sh
new file mode 100644
index 00000000..35555ad9
--- /dev/null
+++ b/tools/run-creative-e2e.sh
@@ -0,0 +1,291 @@
+#!/usr/bin/env bash
+set -euo pipefail
+
+SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
+REPO_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)"
+# shellcheck source=tools/mcc-env.sh
+source "$REPO_ROOT/tools/mcc-env.sh"
+
+usage() {
+ cat <<'EOF'
+Usage: tools/run-creative-e2e.sh