• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Help Whit Zombie Event Error

Bazi

Member
Joined
Oct 24, 2011
Messages
270
Reaction score
8
Location
Germany
Hey ppls from OTLand please help me whit that zombievent Error


PHP:
[29/07/2012 17:11:44] [Error - GlobalEvent Interface] 
[29/07/2012 17:11:44] data/globalevents/scripts/zombie/onthink.lua:onThink
[29/07/2012 17:11:44] Description: 
[29/07/2012 17:11:44] data/lib/zombie_event.lua:105: bad argument #2 to 'random' (interval is empty)
[29/07/2012 17:11:44] stack traceback:
[29/07/2012 17:11:44]     [C]: in function 'random'
[29/07/2012 17:11:44]     data/lib/zombie_event.lua:105: in function 'spawnNewZombie'
[29/07/2012 17:11:44]     data/globalevents/scripts/zombie/onthink.lua:6: in function <data/globalevents/scripts/zombie/onthink.lua:1>
[29/07/2012 17:11:44] [Error - GlobalEvents::think] Couldn't execute event: ZombieGlobalThink

Data/Globalevents/Scripts/Zombie/onthink



PHP:
function onThink(interval, lastExecution, thinkInterval)
    if(getStorage(ZE_STATUS) == 2) then
        setZombiesToSpawnCount(getZombiesToSpawnCount()+1)
        local players = getZombiesEventPlayers()
        for i=1, getZombiesToSpawnCount() * 2 do
            if(getZombiesToSpawnCount() > 1 and spawnNewZombie()) then
                setZombiesToSpawnCount(getZombiesToSpawnCount()-1)
            end
        end
    end
    return true
end

Thx Otland
 
Back
Top