beep boop

This commit is contained in:
Expand 2023-12-17 04:15:15 +11:00
parent 4bdec181ab
commit 19e4b481fa

View file

@ -36,11 +36,15 @@ module.exports = {
}).catch((error) => {
console.log("Server is offline" + error);
serverofflinefor += 10
if(serverofflinefor <= 60){
channelSend(`Server offline for ~${serverofflinefor}`)
if(serverofflinefor > 60 && restarted != 1){
}
if(serverofflinefor == 60 && restarted != 1){
channelSend(`server Offline for 60 seconds Restarting`)
const killer = spawn("screen", ['-XS', 'minecraft'])
const mc = spawn("screen", ['-dmS', 'minecraft', '/bin/bash', `${process.env.SERSTARTLOC}`])
const mc = spawn("screen", ['-dmS', 'minecraft', '/bin/bash', `${process.env.SERSTARTLOC}`], {
cwd: `${process.env.SERSTARTLOC}`
})
restarted = 1
}
});