Browse Source

feat(rustserver): add rust custom map support (#3017)

pull/3033/head
P4R4NORM4L 5 years ago
committed by GitHub
parent
commit
c267953da7
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 26
      lgsm/functions/command_wipe.sh

26
lgsm/functions/command_wipe.sh

@ -77,6 +77,32 @@ fn_wipe_server_files(){
fn_sleep_time fn_sleep_time
fn_script_log_pass "No barren map save to remove." fn_script_log_pass "No barren map save to remove."
fi fi
# Wipe custom map.
if [ -n "$(find "${serveridentitydir}" -type f -name "*.map")" ]; then
echo -en "removing custom map file(s)..."
fn_sleep_time
fn_script_log_info "Removing map file(s): ${serveridentitydir}/*.map"
find "${serveridentitydir:?}" -type f -name "*.map" -delete | tee -a "${lgsmlog}"
fn_wipe_exit_code
fn_sleep_time
else
echo -e "no map file to remove"
fn_sleep_time
fn_script_log_pass "No map file to remove"
fi
# Wipe custom map save.
if [ -n "$(find "${serveridentitydir}" -type f -name "*.sav")" ]; then
echo -en "removing map save *.sav file(s)..."
fn_sleep_time
fn_script_log_info "Removing map save(s): ${serveridentitydir}/*.sav"
find "${serveridentitydir:?}" -type f -name "*.sav" -delete | tee -a "${lgsmlog}"
fn_wipe_exit_code
fn_sleep_time
else
echo -e "no map save to remove"
fn_sleep_time
fn_script_log_pass "No map save to remove."
fi
# Wipe user dir, might be a legacy thing, maybe to be removed. # Wipe user dir, might be a legacy thing, maybe to be removed.
if [ -d "${serveridentitydir}/user" ]; then if [ -d "${serveridentitydir}/user" ]; then
echo -en "removing user directory..." echo -en "removing user directory..."

Loading…
Cancel
Save