Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function onThink()
- local square = {
- frompos = {x = 1252, y = 1007, z = 5},
- topos = {x = 1261, y = 1013, z = 5},
- exitpos = {x = 1253, y = 1010, z = 6}
- }
- local players = 0
- local playerNoMapa
- for a = square.frompos.x, square.topos.x do
- for b = square.frompos.y, square.topos.y do
- local pos = { x = a, y = b, z = 5, stackpos = 255 }
- local player = getTopCreature(pos).uid
- if (isPlayer(player)) then
- playerNoMapa = player
- players = players + 1
- end
- end
- end
- if (players == 1) then
- -- faz a magica aqui
- end
- return true
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement