--Global Arerna -- g_arena=nil g_player=nil function Arena_OnCreate(arena) -- Set our global value g_arena = arena -- Initialize random math.randomseed(os.time()) end function Player_OnWarpItem(plyr, itemid, target) -- player, integer, string if (itemid == 3) then summonall(plyr:coords()) else plyr:message('You have used an invalid warpitem') end return false end function summonall(coords) local numberOfPlayers = g_arena:numPlaying() for i=1, numberOfPlayers do g_arena:message('Break') local person = g_arena:get(i) if (person ~= nil) and (person:valid()) then person:inventory_modify('Summon All', -1) person:warp(coords.x, coords.y, 0) end end end function messagetoteam(team, message) if (team ~= nil) then for i=1, team:num() do local player = team:get(i) if (player ~= nil) and (player:valid()) then player:message(message) end end end end function Msg_OnCommand(plyr, command, payload, recipient, msg_type) -- player, string, string, string, integer if (command == '?coords') then plyr:message('X = ' .. plyr:coords().x .. ' Y = ' .. plyr:coords().y) end end