aqubjukr
Well-Known Member
Anyone know how to limit the spawn of only one creature?
In my script spawns the same quantity of players in lever's SQMs.
In my script spawns the same quantity of players in lever's SQMs.
Lua:
if item.itemid == 1945 and item.actionid == 50456 then
for x = 33520, 33524 do
local playerTile = Tile(Position(x, 31465, 15)):getTopCreature()
if playerTile and playerTile:isPlayer() then
if playerTile:getStorageValue(517711) < os.time() then
playerTile:teleportTo(Position(33484, 31447, 15))
playerTile:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
playerTile:setStorageValue(517711, os.time() + 20 * 60 * 60)
playerTile:sendTextMessage(MESSAGE_INFO_DESCR, "Your team have 10 minutes to kill the boss!")
local monstersStart = monstersSummon.startMonst
for i = 1, #monstersStart do
Game.createMonster(monstersStart[i].monsterName, monstersStart[i].monsterPos, false, true)
end
setGlobalStorageValue(25407, 1)
addEvent(PlayerAreaClear, 10 * 60 * 1000)
addEvent(boosAreaClear, 11 * 60 * 1000)
addEvent(GlobalStorageRevert, 11 * 60 * 1000)
else
return false
end
end
end
end