Skip to content

Commit

Permalink
launch executable in Win64 directory
Browse files Browse the repository at this point in the history
Seems to work more reliably, and is necessary in order for mods to work.
  • Loading branch information
ripps818 committed Feb 16, 2024
1 parent 38938ad commit d2705ec
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ ENV DEBIAN_FRONTEND=noninteractive \
# Path-vars
GAME_ROOT="/palworld" \
GAME_PATH="/palworld/Pal" \
GAME_BIN="${GAME_PATH}/Binaries/Win64/PalServer-Win64-Test-Cmd.exe" \
GAME_SAVE_PATH="/palworld/Pal/Saved" \
GAME_CONFIG_PATH="/palworld/Pal/Saved/Config/WindowsServer" \
GAME_SETTINGS_FILE="/palworld/Pal/Saved/Config/WindowsServer/PalWorldSettings.ini" \
Expand Down
8 changes: 3 additions & 5 deletions includes/server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,17 @@ function start_server() {
send_start_notification
fi
es ">>> Starting the gameserver"
"${WINE_BIN}" PalServer.exe "${START_OPTIONS[@]}"
"${WINE_BIN}" "${GAME_BIN}" "${START_OPTIONS[@]}"
}

function stop_server() {
ew ">>> Stopping server..."
if [[ -n $RCON_ENABLED ]] && [[ $RCON_ENABLED == "true" ]]; then
save_and_shutdown_server
fi
#kill -SIGTERM "$(pidof PalServer-Linux-Test)"
#tail --pid="$(pidof PalServer-Linux-Test)" -f 2>/dev/null
wineserver -k
pkill start.exe
pkill Xvfb
pkill -9 start.exe
pkill -9 Xvfb
if [[ -n $WEBHOOK_ENABLED ]] && [[ $WEBHOOK_ENABLED == "true" ]]; then
send_stop_notification
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/restart.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function schedule_restart() {
#kill -SIGTERM "$(pidof PalServer-Win64-Test.exe)"
#tail --pid="$(pidof PalServer-Win64-Test.exe)" -f 2>/dev/null
wineserver -k
pkill start.exe
pkill -9 start.exe
ew ">>> Server stopped gracefully"
exit 143;
fi
Expand Down
4 changes: 2 additions & 2 deletions scripts/servermanager.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@ function start_main() {
if [ "${WINETRICK_ON_START}" == "true" ]; then
winetricks_install
fi
if [ ! -f "${GAME_ROOT}/PalServer.exe" ]; then
if [ ! -f "${GAME_BIN}" ]; then
fresh_install_server
fi
if [ "${ALWAYS_UPDATE_ON_START}" == "true" ]; then
update_server
fi
echo "${GAME_ROOT}/PalServer.exe"
echo "${GAME_BIN}"
setup_crons
start_server
}
Expand Down

0 comments on commit d2705ec

Please sign in to comment.