9
3

dpoinvisiblecube.lua 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. --[[
  2. Script Name : SpawnScripts/SorcerersTrial/dpoinvisiblecube.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.11.13 04:11:11
  5. Script Purpose :
  6. :
  7. --]]
  8. function spawn(NPC)
  9. end
  10. function respawn(NPC)
  11. spawn(NPC)
  12. end
  13. function Trial1Done(NPC,Spawn)
  14. AddTimer(NPC,2500,"Stage2",1,Spawn)
  15. AddTimer(NPC,3500,"Trial2",1,Spawn)
  16. end
  17. function Trial2Done(NPC,Spawn)
  18. AddTimer(NPC,2500,"Stage3",1,Spawn)
  19. AddTimer(NPC,3500,"Trial3",1,Spawn)
  20. end
  21. function Trial3Done(NPC,Spawn)
  22. AddTimer(NPC,2500,"Stage4",1,Spawn)
  23. AddTimer(NPC,3500,"Trial4",1,Spawn)
  24. end
  25. function Stage2 (NPC,Spawn)
  26. local zone = GetZone(Spawn)
  27. local SummonRing = GetSpawnByLocationID(zone,133780600)
  28. ApplySpellVisual(SummonRing, 100)
  29. end
  30. function Trial2 (NPC,Spawn)
  31. local zone = GetZone(Spawn)
  32. if GetSpawnByLocationID(zone,133780603) == nil then
  33. local Trial2Spawn = SpawnByLocationID(zone,133780628)
  34. end
  35. end
  36. function Stage3 (NPC,Spawn)
  37. local zone = GetZone(Spawn)
  38. local SummonRing = GetSpawnByLocationID(zone,133780600)
  39. ApplySpellVisual(SummonRing, 100)
  40. end
  41. function Trial3 (NPC,Spawn)
  42. local zone = GetZone(Spawn)
  43. if GetSpawnByLocationID(zone,133780601) == nil then
  44. local Trial3Spawn = SpawnByLocationID(zone,133780629)
  45. end
  46. end
  47. function Stage4 (NPC,Spawn)
  48. local zone = GetZone(Spawn)
  49. local SummonRing = GetSpawnByLocationID(zone,133780600)
  50. ApplySpellVisual(SummonRing, 100)
  51. end
  52. function Trial4 (NPC,Spawn)
  53. local zone = GetZone(Spawn)
  54. if GetSpawnByLocationID(zone,133780604) == nil then
  55. local Trial4Spawn = SpawnByLocationID(zone,133780630)
  56. end
  57. end
  58. function Trial4Done(NPC,Spawn)
  59. AddTimer(NPC,2500,"RingDone",1,Spawn)
  60. if GetQuestStep(Spawn,5769)==1 then
  61. SetStepComplete(Spawn,5769,1)
  62. end
  63. end
  64. function RingDone(NPC, Spawn)
  65. local zone = GetZone(Spawn)
  66. local SummonRing = GetSpawnByLocationID(zone,133780600)
  67. SpawnSet(SummonRing,"visual_state",34341)
  68. AddTimer(NPC,3000,"DespawnRing")
  69. end
  70. function DespawnRing(NPC, Spawn)
  71. local zone = GetZone(Spawn)
  72. local SummonRing = GetSpawnByLocationID(zone,133780600)
  73. Despawn(NPC)
  74. end