• 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!
  • If you're using Gesior 2012 or MyAAC, please review this thread for information about a serious security vulnerability and a fix.

TFS 1.2 doesnt execute globalevent (wave event)

Tbol

Active Member
Joined
Apr 7, 2019
Messages
465
Reaction score
47
Using this wave event script GlobalEvent - TFS 1.3 Monster Wave Event (https://otland.net/threads/tfs-1-3-monster-wave-event.273925/)
but for some reason it doesnt execute the globalevent
Code:
<globalevent name="Wavevent" interval="120000" script="wavevent.lua" />
Lua:
local timeWait = 1 -- Time in minutes to wait until trying to start the event. --

function onThink(interval)
    if MW_STATUS == 0 then
        Game.broadcastMessage("Monster wave event is now open. Enter the event portal to particiapte.", 1)
        MW_STATUS = 1
        addEvent(MW_tryEvent, timeWait * 60 * 1000)
    end
    return true
end
 

Xikini

I whore myself out for likes
Senator
Joined
Nov 17, 2010
Messages
6,371
Solutions
550
Reaction score
4,659
Add prints.

Lua:
local timeWait = 1 -- Time in minutes to wait until trying to start the event. --

function onThink(interval)
    print(MW_STATUS)
    if MW_STATUS == 0 then
        Game.broadcastMessage("Monster wave event is now open. Enter the event portal to particiapte.", 1)
        MW_STATUS = 1
        addEvent(MW_tryEvent, timeWait * 60 * 1000)
    end
    return true
end
 
OP
OP
Tbol

Tbol

Active Member
Joined
Apr 7, 2019
Messages
465
Reaction score
47
Add prints.

Lua:
local timeWait = 1 -- Time in minutes to wait until trying to start the event. --

function onThink(interval)
    print(MW_STATUS)
    if MW_STATUS == 0 then
        Game.broadcastMessage("Monster wave event is now open. Enter the event portal to particiapte.", 1)
        MW_STATUS = 1
        addEvent(MW_tryEvent, timeWait * 60 * 1000)
    end
    return true
end
Printed 0 so it means it should have broadcasted a message and opened portal but it didnt
 
Top