How to find these? I was when it's clean its coming up " Auto-Clean in 1 minutes. " and then it comes /clean, when I not type it. Same with Auto Save, I want text when it will be Save.
I need Auto Restart also, Thanks.
function executeSave()
doSaveServer()
doBroadcastMessage("Server saved, next save in 30 minutes.")
return TRUE
end
function onThink(interval, lastExecution)
doBroadcastMessage("Server saving in 1 minute!")
addEvent(executeSave, 100000)
return TRUE
end
function executeClean()
doCleanMap()
doBroadcastMessage("Game map cleaned, next clean in 2 hours.")
return TRUE
end
function onThink(interval, lastExecution)
doBroadcastMessage("Game map cleaning within 1 minute, please pick up your items!")
addEvent(executeClean, 100000)
return TRUE
end
<globalevent name="save" interval="1800" event="script" value="save.lua"/>
<globalevent name="clean" interval="7200" event="script" value="clean.lua"/>
function onSay (cid, msg, param)
local clean = doCleanMap()
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESC, "The cleaning command collected " .. clean .. " items from the floor. Enjoy your new cleaner server.")
end
The cleaning command collected 65535 items from the floor. Enjoy your new cleaner server.
doBroadcastMessage("Game map cleaning within 1 minute, please pick up your items!")
addEvent(executeClean, 100000)
Hello!
Can anybody make an script for "Auto Reset" every 24h?
This person which do this will be reputet!
from when 100 seconds is 1 minute :<?
Please use the request board next time.
Anyway, I'll help you.
Go to /data/globalevents/scripts/
Create a new lua file called save.lua
Insert:
Then create another lua file called clean.luaCode:function executeSave() doSaveServer() doBroadcastMessage("Server saved, next save in 30 minutes.") return TRUE end function onThink(interval, lastExecution) doBroadcastMessage("Server saving in 1 minute!") addEvent(executeSave, 100000) return TRUE end
Insert:
Then go to /data/globalevents/ and open globalevents.xmlCode:function executeClean() doCleanMap() doBroadcastMessage("Game map cleaned, next clean in 2 hours.") return TRUE end function onThink(interval, lastExecution) doBroadcastMessage("Game map cleaning within 1 minute, please pick up your items!") addEvent(executeClean, 100000) return TRUE end
Add these 2 lines:
Code:<globalevent name="save" interval="1800" event="script" value="save.lua"/> <globalevent name="clean" interval="7200" event="script" value="clean.lua"/>