2022-03-02 17:29:12 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# shellcheck source=start-utils
|
|
|
|
. "${SCRIPTS:-/}start-utils"
|
|
|
|
|
|
|
|
: "${RCON_CMDS_STARTUP:=}"
|
|
|
|
: "${RCON_CMDS_ON_CONNECT:=}"
|
|
|
|
: "${RCON_CMDS_ON_DISCONNECT:=}"
|
2022-03-04 02:47:30 +00:00
|
|
|
: "${RCON_CMDS_FIRST_CONNECT:=}"
|
|
|
|
: "${RCON_CMDS_LAST_DISCONNECT:=}"
|
2022-03-02 17:29:12 +00:00
|
|
|
: "${RCON_CMDS_PERIOD:=10}"
|
|
|
|
: "${SERVER_PORT:=25565}"
|
|
|
|
export RCON_CMDS_STARTUP
|
|
|
|
export RCON_CMDS_ON_CONNECT
|
|
|
|
export RCON_CMDS_ON_DISCONNECT
|
2022-03-04 22:52:00 +00:00
|
|
|
export RCON_CMDS_FIRST_CONNECT
|
2022-03-04 02:47:30 +00:00
|
|
|
export RCON_CMDS_LAST_DISCONNECT
|
2022-03-02 17:29:12 +00:00
|
|
|
export RCON_CMDS_PERIOD
|
|
|
|
export SERVER_PORT
|
|
|
|
|
|
|
|
log "Rcon cmds functionality enabled"
|
|
|
|
|
|
|
|
isDebugging && set -x
|
|
|
|
|
2024-10-22 21:04:38 +00:00
|
|
|
isNumericElseSetToDefault RCON_CMDS_PERIOD 10
|
|
|
|
checkIfNotZeroElseSetToDefault RCON_CMDS_PERIOD 10
|
2022-03-02 17:29:12 +00:00
|
|
|
|
2022-09-03 21:48:14 +00:00
|
|
|
/usr/local/bin/rcon-cmds-daemon.sh &
|