Files
minecraft-ai-god-paper-fork/scripts/mc_godmode_watch.sh
T
Seth 8ee8be9cc0 Initial commit — Minecraft AI God plugin
- mc_aigod.py: main watcher script (log tail, RCON, two-call LLM)
- Two-call LLM split: qwen3-coder:30b for commands, gemma3:12b for messages
- Divine intervention timer (Poisson process, configurable avg/day)
- Prayer memory (persistent, last 10 exchanges)
- Rolling server log context (last 20 min events)
- Live player context (inventory with rarity, health, food, pos, XP)
- /pray and bible chat detection (no slash — vanilla 1.21 compatible)
- Login notice, bible help system
- debug_commands toggle (in-game command display via tellraw)
- Auto-fix for transposed give command syntax
- JSON repair fallback for truncated LLM responses
- Sentence-aware message chunking for long responses
- mc-aigod.service systemd unit
- mc_aigod_shrink.json example config
- README.md full implementation guide
- Minecraft_Ai_God.md full design document
2026-03-15 19:02:16 -04:00

15 lines
498 B
Bash

#!/bin/bash
# Watches mc1 log for slingshooter08 joining and applies creative mode.
# Deployed to: /usr/local/bin/mc_godmode_watch.sh on CT 644
# Managed by: mc-godmode.service
LOG=/opt/mcsmanager/daemon/data/InstanceData/d39f55861cb34204a92a18a9e1c78ca6/logs/latest.log
PLAYER=slingshooter08
tail -F "$LOG" | grep --line-buffered "joined the game" | while read line; do
if echo "$line" | grep -qi "$PLAYER"; then
sleep 1
python3 /usr/local/bin/mc_godmode_rcon.py
fi
done