archean-server-pelican/archean_start.sh
2024-10-18 22:15:37 +02:00

12 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
sed "s/^game_mode=.*/game_mode=$( [ "$GAME_MODE" = "creative" ] && echo 0 || echo 1)/" server/server.ini > server/server.ini
sed "s/^server_online=.*/server_online=$( [ "$ONLINE_MODE" = "0" ] && echo no || echo yes)/" server/server.ini > server/server.ini
sed "s/^max_simultaneous_players=.*/max_simultaneous_players=$MAX_PLAYERS/" server/server.ini > server/server.ini
sed "s/^password=.*/password=$PASSWORD/" server/server.ini > server/server.ini
sed "s/^server_public_name=.*/server_public_name=$NAME/" server/server.ini > server/server.ini
sed "s/^listen_port=.*/listen_port=$SERVER_PORT/" server/server.ini > server/server.ini
sed "s/^spawn=.*/spawn=$SPAWN_PLANET/" server/server.ini > server/server.ini
sed "s/^auto_save_interval_seconds=.*/auto_save_interval_seconds=$AUTOSAVE_INTERVAL/" server/server.ini > server/server.ini
sed "s/^updates_per_second=.*/updates_per_second=$UPDATES_PER_SECOND/" server/server.ini > server/server.ini
sed "s/^physics_steps_per_update=.*/physics_steps_per_update=$PHYSICS_UPDATES_PER_UPDATE/" server/server.ini > server/server.ini