kito2
www.masteria.net
I have this lua but I can't understand why it just works once on one script... I add this to anothers scripts (talkactions/creaturescripts/globalevents) and doesn't work... Actually it works on a raid script... Any ideas?
I need a function maybe to be added on lib and then could be used on every single script...
LUA:
local from = {x = 16, y = 12, z = 5}
local to = {x = 95, y = 81, z = 5}
local monsters = {}
for x = from.x, to.x do
for y = from.y, to.y do
local v = getTopCreature({x = x, y = y, z = 5}).uid
if isPlayer(v) then
return true
elseif isMonster(v) then
table.insert(monsters, v)
end
end
end
for i = 1, #monsters do
doRemoveCreature(monsters[i])
end
I need a function maybe to be added on lib and then could be used on every single script...
Last edited: