• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

TFS 0.X MOD Tfs 0.4 Firestorm Event - Days

FearWar

Active Member
Joined
Sep 17, 2017
Messages
221
Reaction score
26
Location
Brasil
Hi otlanders,

There is this part of the code in my event, but I wanted to add the days of the week and the times someone help me?

Example:

XML:
    ["Monday"] = {"09:30","12:00","20:00"},
    ["Tuesday"] = {"09:30","12:00","20:00"},
    ["Wednesday"] = {"09:30","12:00","20:00"},
    ["Thursday"] = {"09:30","12:00","20:00"},
    ["Friday"] = {"09:30","12:00","20:00"},
    ["Saturday"] = {"09:30","12:00","20:00"},
    ["Sunday"] = {"09:30","12:00","20:00"}

XML:
<globalevent name="fireStormTime" time="15:02" event="script"><![CDATA[
domodlib("fireStorm_conf")
function onTime(time)
addEvent(function()
if getStorage(fireStormStorageStatus) == 2 then return true end
if getStorage(fireStormStorageStatus) == 1 and #getFireStormEventPlayers() >= fireStormMinPlayers then
doSetStorage(fireStormStorageStatus, 2)
addEvent(spawnNewFire, fireStormShootInterval * 1000, fireStormBaseFireShoots, fireStormBaseFireShoots)
for _, v in ipairs(getFireStormEventPlayers()) do
addPlayerToFireStormArea(v, false)
end
return enableMessage and doBroadcastMessage('Fire Storm Event is started. We have '..#getFireStormEventPlayers()..' players on area') or true
end
for _, v in ipairs(getFireStormEventPlayers()) do
kickPlayerFromFireStormArea(v)
end
return enableMessage and doBroadcastMessage('Fire Storm Event is stopped. We could not find enough players.') or true
end,
timeOnJoinToEvent * 1000 * 60)
return startFireStormEvent()
end
]]></globalevent>

Help me?
 
Back
Top