mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2026-08-15 13:04:36 +00:00
chore: remove remaining CursorBot references
This commit is contained in:
parent
ca5c9f73e3
commit
8e0db1402f
5 changed files with 51 additions and 48 deletions
|
|
@ -19,7 +19,7 @@ This skill uses a fixed set of stable commands for local offline integration tes
|
||||||
- `look east`
|
- `look east`
|
||||||
- `/gamemode survival`
|
- `/gamemode survival`
|
||||||
- `respawn`
|
- `respawn`
|
||||||
- `/tp CursorBot 0 -60 0`
|
- `/tp MCCBot 0 -60 0`
|
||||||
- `smoke_test_from_mcc_full_spectrum`
|
- `smoke_test_from_mcc_full_spectrum`
|
||||||
- `integration_test_chat_response`
|
- `integration_test_chat_response`
|
||||||
|
|
||||||
|
|
@ -29,63 +29,63 @@ Notes:
|
||||||
|
|
||||||
## Server-side commands via `mc-rcon`
|
## Server-side commands via `mc-rcon`
|
||||||
|
|
||||||
- `op CursorBot`
|
- `op MCCBot`
|
||||||
- `gamerule sendCommandFeedback true`
|
- `gamerule sendCommandFeedback true`
|
||||||
- `gamerule logAdminCommands true`
|
- `gamerule logAdminCommands true`
|
||||||
- `time set day`
|
- `time set day`
|
||||||
- `weather clear`
|
- `weather clear`
|
||||||
- `say Hello from the server console`
|
- `say Hello from the server console`
|
||||||
- `msg CursorBot This is a private whisper`
|
- `msg MCCBot This is a private whisper`
|
||||||
- `effect give CursorBot minecraft:speed 30 1`
|
- `effect give MCCBot minecraft:speed 30 1`
|
||||||
- `effect give CursorBot minecraft:regeneration 10 1`
|
- `effect give MCCBot minecraft:regeneration 10 1`
|
||||||
- `kill CursorBot`
|
- `kill MCCBot`
|
||||||
|
|
||||||
## Representative entity coverage
|
## Representative entity coverage
|
||||||
|
|
||||||
- `execute as CursorBot at @s run summon minecraft:cow ~2 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:cow ~2 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:zombie ~4 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:zombie ~4 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:creeper ~6 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:creeper ~6 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:skeleton ~8 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:skeleton ~8 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:villager ~-2 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:villager ~-2 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:allay ~-4 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:allay ~-4 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:armor_stand ~ ~ ~2`
|
- `execute as MCCBot at @s run summon minecraft:armor_stand ~ ~ ~2`
|
||||||
- `execute as CursorBot at @s run summon minecraft:item_display ~-6 ~ ~ {item:{id:"minecraft:diamond",count:1}}`
|
- `execute as MCCBot at @s run summon minecraft:item_display ~-6 ~ ~ {item:{id:"minecraft:diamond",count:1}}`
|
||||||
- `execute as CursorBot at @s run summon minecraft:spider ~10 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:spider ~10 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:pig ~-8 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:pig ~-8 ~ ~`
|
||||||
|
|
||||||
## Block placement coverage
|
## Block placement coverage
|
||||||
|
|
||||||
- `execute as CursorBot at @s run fill ~1 ~ ~1 ~3 ~2 ~3 minecraft:stone`
|
- `execute as MCCBot at @s run fill ~1 ~ ~1 ~3 ~2 ~3 minecraft:stone`
|
||||||
- `execute as CursorBot at @s run setblock ~5 ~ ~5 minecraft:chest`
|
- `execute as MCCBot at @s run setblock ~5 ~ ~5 minecraft:chest`
|
||||||
- `execute as CursorBot at @s run setblock ~5 ~1 ~5 minecraft:furnace`
|
- `execute as MCCBot at @s run setblock ~5 ~1 ~5 minecraft:furnace`
|
||||||
- `execute as CursorBot at @s run setblock ~6 ~ ~5 minecraft:crafting_table`
|
- `execute as MCCBot at @s run setblock ~6 ~ ~5 minecraft:crafting_table`
|
||||||
|
|
||||||
## Dimension change coverage
|
## Dimension change coverage
|
||||||
|
|
||||||
- `execute in minecraft:the_nether run tp CursorBot 0 64 0`
|
- `execute in minecraft:the_nether run tp MCCBot 0 64 0`
|
||||||
- `execute in minecraft:overworld run tp CursorBot 0 -60 0`
|
- `execute in minecraft:overworld run tp MCCBot 0 -60 0`
|
||||||
|
|
||||||
## Representative particle coverage
|
## Representative particle coverage
|
||||||
|
|
||||||
- `execute as CursorBot at @s run particle minecraft:happy_villager ~ ~1 ~ 0.5 0.5 0.5 0 12 force`
|
- `execute as MCCBot at @s run particle minecraft:happy_villager ~ ~1 ~ 0.5 0.5 0.5 0 12 force`
|
||||||
- `execute as CursorBot at @s run particle minecraft:end_rod ~ ~1 ~ 0.5 0.5 0.5 0.01 20 force`
|
- `execute as MCCBot at @s run particle minecraft:end_rod ~ ~1 ~ 0.5 0.5 0.5 0.01 20 force`
|
||||||
- `execute as CursorBot at @s run particle minecraft:explosion ~ ~1 ~ 0 0 0 0 1 force`
|
- `execute as MCCBot at @s run particle minecraft:explosion ~ ~1 ~ 0 0 0 0 1 force`
|
||||||
- `execute as CursorBot at @s run particle minecraft:totem_of_undying ~ ~1 ~ 0.5 0.5 0.5 0.1 20 force`
|
- `execute as MCCBot at @s run particle minecraft:totem_of_undying ~ ~1 ~ 0.5 0.5 0.5 0.1 20 force`
|
||||||
- `execute as CursorBot at @s run particle minecraft:flame ~ ~1 ~ 0.2 0.2 0.2 0.02 30 force`
|
- `execute as MCCBot at @s run particle minecraft:flame ~ ~1 ~ 0.2 0.2 0.2 0.02 30 force`
|
||||||
- `execute as CursorBot at @s run particle minecraft:heart ~ ~2 ~ 0.3 0.3 0.3 0 5 force`
|
- `execute as MCCBot at @s run particle minecraft:heart ~ ~2 ~ 0.3 0.3 0.3 0 5 force`
|
||||||
|
|
||||||
## Representative sound coverage
|
## Representative sound coverage
|
||||||
|
|
||||||
- `execute as CursorBot at @s run playsound minecraft:entity.lightning_bolt.thunder master CursorBot ~ ~ ~ 1 1 0`
|
- `execute as MCCBot at @s run playsound minecraft:entity.lightning_bolt.thunder master MCCBot ~ ~ ~ 1 1 0`
|
||||||
- `execute as CursorBot at @s run playsound minecraft:block.note_block.bell master CursorBot ~ ~ ~ 1 1 0`
|
- `execute as MCCBot at @s run playsound minecraft:block.note_block.bell master MCCBot ~ ~ ~ 1 1 0`
|
||||||
- `execute as CursorBot at @s run playsound minecraft:entity.experience_orb.pickup master CursorBot ~ ~ ~ 1 1 0`
|
- `execute as MCCBot at @s run playsound minecraft:entity.experience_orb.pickup master MCCBot ~ ~ ~ 1 1 0`
|
||||||
|
|
||||||
## Explosion coverage
|
## Explosion coverage
|
||||||
|
|
||||||
- `execute as CursorBot at @s run summon minecraft:tnt ~3 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:tnt ~3 ~ ~`
|
||||||
- `execute as CursorBot at @s run summon minecraft:tnt ~6 ~ ~`
|
- `execute as MCCBot at @s run summon minecraft:tnt ~6 ~ ~`
|
||||||
|
|
||||||
## Kill and respawn cycle
|
## Kill and respawn cycle
|
||||||
|
|
||||||
- `kill CursorBot` (via RCON, requires survival mode)
|
- `kill MCCBot` (via RCON, requires survival mode)
|
||||||
- `respawn` (via MCC command after death)
|
- `respawn` (via MCC command after death)
|
||||||
|
|
|
||||||
|
|
@ -28,11 +28,11 @@ if [[ $# -ge 3 && -f "$1" ]]; then
|
||||||
TEMPLATE_INI="$1"
|
TEMPLATE_INI="$1"
|
||||||
OUTPUT_INI="$2"
|
OUTPUT_INI="$2"
|
||||||
MC_VERSION="$3"
|
MC_VERSION="$3"
|
||||||
LOGIN_NAME="${4:-CursorBot}"
|
LOGIN_NAME="${4:-MCCBot}"
|
||||||
else
|
else
|
||||||
OUTPUT_INI="$1"
|
OUTPUT_INI="$1"
|
||||||
MC_VERSION="$2"
|
MC_VERSION="$2"
|
||||||
LOGIN_NAME="${3:-CursorBot}"
|
LOGIN_NAME="${3:-MCCBot}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ACCOUNT_TYPE="${MCC_TEST_ACCOUNT_TYPE:-mojang}"
|
ACCOUNT_TYPE="${MCC_TEST_ACCOUNT_TYPE:-mojang}"
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,8 @@ fi
|
||||||
SERVER_DIR="$1"
|
SERVER_DIR="$1"
|
||||||
MC_VERSION="$2"
|
MC_VERSION="$2"
|
||||||
PROFILE="$3"
|
PROFILE="$3"
|
||||||
|
SESSION_NAME="achievements-${SERVER_DIR//[^a-zA-Z0-9]/_}-${PROFILE}"
|
||||||
|
TEST_USERNAME="$(_mcc_resolve_username "$SESSION_NAME")"
|
||||||
|
|
||||||
if [[ "$PROFILE" != "legacy" && "$PROFILE" != "modern" ]]; then
|
if [[ "$PROFILE" != "legacy" && "$PROFILE" != "modern" ]]; then
|
||||||
echo "Unsupported profile: $PROFILE" >&2
|
echo "Unsupported profile: $PROFILE" >&2
|
||||||
|
|
@ -55,11 +57,11 @@ COMMAND_LOG="$RUN_DIR/commands.log"
|
||||||
SUMMARY_ENV="$RUN_DIR/summary.env"
|
SUMMARY_ENV="$RUN_DIR/summary.env"
|
||||||
PROBE_SCRIPT="$RUN_DIR/achievement_probe.cs"
|
PROBE_SCRIPT="$RUN_DIR/achievement_probe.cs"
|
||||||
CFG="$RUN_DIR/MinecraftClient.$MC_VERSION.ini"
|
CFG="$RUN_DIR/MinecraftClient.$MC_VERSION.ini"
|
||||||
INPUT_FILE="$REPO_ROOT/mcc_input.txt"
|
INPUT_FILE="$(_mcc_session_input_file "$SESSION_NAME")"
|
||||||
SERVER_LOG_FILE="$MCC_SERVERS/$SERVER_DIR/logs/latest.log"
|
SERVER_LOG_FILE="$MCC_SERVERS/$SERVER_DIR/logs/latest.log"
|
||||||
TARGET_ID="minecraft:story/root"
|
TARGET_ID="minecraft:story/root"
|
||||||
TARGET_COMMAND_GRANT="advancement grant CursorBot only minecraft:story/root"
|
TARGET_COMMAND_GRANT="advancement grant $TEST_USERNAME only minecraft:story/root"
|
||||||
TARGET_COMMAND_REVOKE="advancement revoke CursorBot only minecraft:story/root"
|
TARGET_COMMAND_REVOKE="advancement revoke $TEST_USERNAME only minecraft:story/root"
|
||||||
TARGET_TYPE="Modern 🌱"
|
TARGET_TYPE="Modern 🌱"
|
||||||
PORT="unknown"
|
PORT="unknown"
|
||||||
MCC_PID=""
|
MCC_PID=""
|
||||||
|
|
@ -74,8 +76,8 @@ EXECUTED="yes"
|
||||||
|
|
||||||
if [[ "$PROFILE" == "legacy" ]]; then
|
if [[ "$PROFILE" == "legacy" ]]; then
|
||||||
TARGET_ID="achievement.openInventory"
|
TARGET_ID="achievement.openInventory"
|
||||||
TARGET_COMMAND_GRANT="achievement give achievement.openInventory CursorBot"
|
TARGET_COMMAND_GRANT="achievement give achievement.openInventory $TEST_USERNAME"
|
||||||
TARGET_COMMAND_REVOKE="achievement take achievement.openInventory CursorBot"
|
TARGET_COMMAND_REVOKE="achievement take achievement.openInventory $TEST_USERNAME"
|
||||||
TARGET_TYPE="Legacy 🧱"
|
TARGET_TYPE="Legacy 🧱"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
@ -286,7 +288,7 @@ if [[ ! -d "$MCC_SERVERS/$SERVER_DIR" ]]; then
|
||||||
fail "Server directory not found: $MCC_SERVERS/$SERVER_DIR"
|
fail "Server directory not found: $MCC_SERVERS/$SERVER_DIR"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
bash "$SCRIPT_DIR/prepare_offline_mcc_config.sh" "$CFG" "$MC_VERSION" CursorBot >/dev/null || fail "Failed to prepare temporary MCC config."
|
bash "$SCRIPT_DIR/prepare_offline_mcc_config.sh" "$CFG" "$MC_VERSION" "$TEST_USERNAME" >/dev/null || fail "Failed to prepare temporary MCC config."
|
||||||
PORT="$(bash "$SCRIPT_DIR/get_server_port.sh" "$SERVER_DIR")"
|
PORT="$(bash "$SCRIPT_DIR/get_server_port.sh" "$SERVER_DIR")"
|
||||||
|
|
||||||
"$SCRIPT_DIR/ensure_offline_server.sh" "$SERVER_DIR"
|
"$SCRIPT_DIR/ensure_offline_server.sh" "$SERVER_DIR"
|
||||||
|
|
@ -296,6 +298,7 @@ if [[ "$PROFILE" == "legacy" && -f "$MCC_SERVERS/$SERVER_DIR/server.properties"
|
||||||
sed_in_place 's/^use-native-transport=.*/use-native-transport=false/' "$MCC_SERVERS/$SERVER_DIR/server.properties"
|
sed_in_place 's/^use-native-transport=.*/use-native-transport=false/' "$MCC_SERVERS/$SERVER_DIR/server.properties"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
mkdir -p "$(dirname "$INPUT_FILE")"
|
||||||
: > "$INPUT_FILE"
|
: > "$INPUT_FILE"
|
||||||
rm -f "$MCC_LOG"
|
rm -f "$MCC_LOG"
|
||||||
|
|
||||||
|
|
@ -306,9 +309,9 @@ wait_for_server_ready "$SERVER_DIR" || fail "Server did not become ready."
|
||||||
log_step "Starting MCC for $MC_VERSION"
|
log_step "Starting MCC for $MC_VERSION"
|
||||||
(
|
(
|
||||||
cd "$REPO_ROOT"
|
cd "$REPO_ROOT"
|
||||||
MCC_FILE_INPUT=1 dotnet run --project MinecraftClient -c Release --no-build -- \
|
MCC_FILE_INPUT=1 MCC_INPUT_FILE="$INPUT_FILE" dotnet run --project MinecraftClient -c Release --no-build -- \
|
||||||
"$CFG" \
|
"$CFG" \
|
||||||
CursorBot \
|
"$TEST_USERNAME" \
|
||||||
- \
|
- \
|
||||||
"localhost:$PORT" \
|
"localhost:$PORT" \
|
||||||
"--accounttype=mojang" \
|
"--accounttype=mojang" \
|
||||||
|
|
@ -323,9 +326,9 @@ log_step "Starting MCC for $MC_VERSION"
|
||||||
MCC_PID=$!
|
MCC_PID=$!
|
||||||
|
|
||||||
wait_for_file_pattern "$MCC_LOG" "Server was successfully joined." "MCC join success" 90 || fail "MCC failed to join."
|
wait_for_file_pattern "$MCC_LOG" "Server was successfully joined." "MCC join success" 90 || fail "MCC failed to join."
|
||||||
wait_for_file_pattern "$SERVER_LOG_FILE" "CursorBot joined the game" "server join entry" 30 || fail "Server never logged the join."
|
wait_for_file_pattern "$SERVER_LOG_FILE" "$TEST_USERNAME joined the game" "server join entry" 30 || fail "Server never logged the join."
|
||||||
|
|
||||||
run_server_command "op CursorBot"
|
run_server_command "op $TEST_USERNAME"
|
||||||
run_server_command "gamerule sendCommandFeedback true"
|
run_server_command "gamerule sendCommandFeedback true"
|
||||||
if [[ "$PROFILE" == "modern" ]]; then
|
if [[ "$PROFILE" == "modern" ]]; then
|
||||||
run_server_command "gamerule logAdminCommands true"
|
run_server_command "gamerule logAdminCommands true"
|
||||||
|
|
|
||||||
|
|
@ -22,4 +22,4 @@ echo "MCC highlights:"
|
||||||
grep -E "Server was successfully joined|FileInput|smoke_test_from_mcc_full_spectrum|There are [0-9]+ of a max|health|Creative" "$MCC_LOG" || true
|
grep -E "Server was successfully joined|FileInput|smoke_test_from_mcc_full_spectrum|There are [0-9]+ of a max|health|Creative" "$MCC_LOG" || true
|
||||||
echo
|
echo
|
||||||
echo "Server highlights:"
|
echo "Server highlights:"
|
||||||
grep -E "joined the game|Made CursorBot a server operator|game mode|smoke_test_from_mcc_full_spectrum|summon|particle|playsound|tnt" "$SERVER_LOG" || true
|
grep -E "joined the game|Made .* a server operator|game mode|smoke_test_from_mcc_full_spectrum|summon|particle|playsound|tnt" "$SERVER_LOG" || true
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ try
|
||||||
|
|
||||||
ToolEnvelope initialWorldState = await CallSuccessAsync(client, executed, "mcc_world_state");
|
ToolEnvelope initialWorldState = await CallSuccessAsync(client, executed, "mcc_world_state");
|
||||||
JsonElement initialWorldData = RequireData(initialWorldState);
|
JsonElement initialWorldData = RequireData(initialWorldState);
|
||||||
string botName = ReadString(initialWorldData, "username") ?? "CursorBot";
|
string botName = ReadString(initialWorldData, "username") ?? "MCCBot";
|
||||||
Coordinate initialLocation = ReadCoordinate(initialWorldData, "location");
|
Coordinate initialLocation = ReadCoordinate(initialWorldData, "location");
|
||||||
|
|
||||||
long setupBaseline = 0;
|
long setupBaseline = 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue