Advertisement
Guest User

Untitled

a guest
Nov 21st, 2012
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. function Falling_Custom_Zone(unit, event)
  2. unit:RegisterEvent("FallingCustomZone", 2009, 0)
  3. end
  4.  
  5. function FallingCustomZone(unit, event, player)
  6. for k, v in pairs(unit:GetInRangePlayers()) do
  7. if (unit:GetDistance(v) < 6) then
  8. local race=v:GetPlayerRace()
  9. if race==2 or race==5 or race==6 or race==8 or race==10 then -- Alliance
  10. v:CastSpell(64446)
  11. v:CastSpell(5)
  12. v:Teleport(1, 16558.873047, 15584.223633, 35.402008)
  13. v:SendBroadcastMessage("That water is awfully cold.")
  14. else -- below = Horde
  15. v:CastSpell(64446)
  16. v:CastSpell(5)
  17. v:Teleport(1, 15892.689453, 15629.592773, 37.526806)
  18. v:SendBroadcastMessage("That water is awfully cold.")
  19. end
  20. end
  21. end
  22. end
  23.  
  24.  
  25. RegisterUnitEvent(271570, 18, "Falling_Custom_Zone")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement