9
3

invisiblecube2.lua 1.5 KB

12345678910111213141516171819202122232425262728293031323334
  1. --[[
  2. Script Name : SpawnScripts/Baubbleshire/invisiblecube2.lua
  3. Script Author : Dorbin
  4. Script Date : 2023.03.16 07:03:26
  5. Script Purpose :
  6. :
  7. --]]
  8. function spawn(NPC)
  9. SetPlayerProximityFunction(NPC, 6, "InRange", "LeaveRange")
  10. end
  11. function InRange(NPC, Spawn) --Quest Callout
  12. if GetFactionAmount(Spawn,11)>-1 then
  13. --QUEST CHECK, CHECKS EACH RACE SUBURB
  14. if not HasQuest(Spawn,5760) and not HasCompletedQuest(Spawn, 5760) and
  15. not HasQuest(Spawn,5761) and not HasCompletedQuest(Spawn, 5761) and
  16. not HasQuest(Spawn,5762) and not HasCompletedQuest(Spawn, 5762) and
  17. not HasQuest(Spawn,5763) and not HasCompletedQuest(Spawn, 5763) and
  18. not HasQuest(Spawn,5764) and not HasCompletedQuest(Spawn, 5764) and
  19. not HasQuest(Spawn,5765) and not HasCompletedQuest(Spawn, 5765) and
  20. --QUEST CHECK FOR ISLE OF REFUGE QUEST AND OFFERED QUEST
  21. not HasQuest(Spawn, 5717) and not HasQuest(Spawn, 5792) then
  22. OfferQuest(NPC,Spawn,5792)
  23. conversation = CreateConversation()
  24. PlayFlavor(Spawn, "voiceover/english/queen_antonia_bayle/qey_north/antonia_isle_speech_10.mp3", "", "", 1463066361, 618547599, Spawn)
  25. AddConversationOption(conversation, " ")
  26. StartDialogConversation(conversation, 1, NPC, Spawn, "The voice of Queen Antonia Bayle enters your mind as you step forward... \n\n\"All who yearn to fully participate in the center of Qeynos must first prove themselves.\"")
  27. end
  28. end
  29. end
  30. function respawn(NPC)
  31. spawn(NPC)
  32. end