Anyone can help me here? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Anyone can help me here? (
/showthread.php?tid=621964)
Anyone can help me here? -
PrinceKumar - 17.11.2016
Код:
#!/bin/bash
function startServer(){
NUMSECONDS=`expr $(date +%s)`
until ./samp03svr ; do
let DIFF=(`date +%s` - "$NUMSECONDS")
if [ "$DIFF" -gt 15 ]; then
NUMSECONDS=`expr $(date +%s)`
echo "Server './samp03svr ' crashed with exit code $?. Respawning..." >&2
fi
sleep 3
done
let DIFF=(`date +%s` - "$NUMSECONDS")
if [ ! -e "SERVER_STOPPED" ] && [ "$DIFF" -gt 15 ]; then
startServer
fi
}
startServer
Re: Anyone can help me here? -
PrinceKumar - 17.11.2016
Anyone help me please
Re: Anyone can help me here? -
PrinceKumar - 17.11.2016
Anyone please help me
Re: Anyone can help me here? -
SyS - 17.11.2016
Wait lemme do some magic spell to find out what is your problem.
Re: Anyone can help me here? -
PrinceKumar - 17.11.2016
Okay