Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --#config#
- local townId = 1
- local timer = 100 -- 100 ms para cada pingo
- local range = 5 -- raio de variação
- local defec = 0
- local mefec = 2160
- function onThink(interval)
- local pos = getTownTemplePosition(townId)
- for i=0, math.floor(interval/timer) do
- rain(pos, range, defec, mefec)
- end
- return true
- end
- function rain(pos, range, defec, mefec)
- addEvent(function()
- local fromPos = {x = pos.x -6, y = pos.y -6, z = pos.z}
- local newPos = {x = pos.x, y = pos.y, z = pos.z}
- newPos.x = newPos.x + math.random(-range, range)
- newPos.y = newPos.y + math.random(-range, range)
- doSendDistanceShoot(fromPos, newPos, defec)
- doSendMagicEffect(newPos, mefec)
- end, timer)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement