ThunderingSteppes.lua 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. --[[
  2. Script Name : ThunderingSteppes.lua
  3. Script Purpose : Handle various things around the steppes
  4. Script Author : Jabantiz
  5. Script Date : 7/11/2015
  6. Script Notes :
  7. --]]
  8. -- Location ID's for the doors
  9. local NorthDoor = 1437017
  10. local SouthDoor = 1437013
  11. local NorthDoorClosed = 352
  12. local SouthDoorClosed = 170
  13. function init_zone_script(zone)
  14. SetLocationProximityFunction(zone, 172.5, 18.5, -880.97, 10, "GriffonTower", "Leave") -- Ant Gate
  15. SetLocationProximityFunction(zone, -174.68, 13.41, 509.50, 10, "GriffonTower", "Leave") -- SE Station
  16. SetLocationProximityFunction(zone, 254.41, -8.92, 1343.37, 10, "GriffonTower", "Leave") -- ColdWind
  17. SetLocationProximityFunction(zone, 622.95, 18.45, -234.11, 10, "GriffonTower", "Leave") -- Thundermist
  18. SetLocationProximityFunction(zone, -394.25, -23.21, -418.25, 10, "GriffonTower", "Leave") -- Docks
  19. end
  20. function player_entry(zone, player)
  21. end
  22. function enter_location(zone, spawn, grid)
  23. end
  24. function leave_location(zone, spawn, grid)
  25. end
  26. function dawn(zone)
  27. local door1 = GetSpawnByLocationID(zone, NorthDoor)
  28. local door2 = GetSpawnByLocationID(zone, SouthDoor)
  29. if door1 ~= nil then
  30. if GetHeading(door1) == NorthDoorClosed then
  31. UseWidget(door1)
  32. end
  33. end
  34. if door2 ~= nil then
  35. if GetHeading(door2) == SouthDoorClosed then
  36. UseWidget(door2)
  37. end
  38. end
  39. end
  40. function dusk(zone)
  41. local door1 = GetSpawnByLocationID(zone, NorthDoor)
  42. local door2 = GetSpawnByLocationID(zone, SouthDoor)
  43. if door1 ~= nil then
  44. if GetHeading(door1) ~= NorthDoorClosed then
  45. UseWidget(door1)
  46. end
  47. end
  48. if door2 ~= nil then
  49. if GetHeading(door2) ~= SouthDoorClosed then
  50. UseWidget(door2)
  51. end
  52. end
  53. end
  54. function GriffonTower(zone, Spawn)
  55. if IsPlayer(Spawn) and IsOnAutoMount(Spawn) then
  56. EndAutoMount(Spawn)
  57. end
  58. end
  59. function Leave(zone, Spawn)
  60. end