HaroldDunstan.lua 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. --[[
  2. Script Name : SpawnScripts/NorthQeynos/HaroldDunstan.lua
  3. Script Purpose : Harold Dunstan
  4. Script Author : Dorbin
  5. Script Date : 2022.04.22
  6. Script Notes :
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. Cake = 5580
  10. function spawn(NPC)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function hailed(NPC, Spawn)
  16. if GetFactionAmount(Spawn,11) <0 then
  17. choice = math.random(1,2)
  18. if choice == 1 then
  19. PlayFlavor(NPC, "", "", "shakefist", 2088886924, 3736631596, Spawn)
  20. elseif choice == 2 then
  21. PlayFlavor(NPC, "", "", "heckno", 1584866727, 581589457, Spawn)
  22. end
  23. else
  24. Dialog1(NPC, Spawn)
  25. SetTarget(NPC,Spawn)
  26. end
  27. end
  28. function Dialog1(NPC, Spawn)
  29. FaceTarget(NPC, Spawn)
  30. Dialog.New(NPC, Spawn)
  31. Dialog.AddDialog("Hail traveler. Can I offer you a drink to quench your thirst?")
  32. Dialog.AddVoiceover("voiceover/english/harold_dunstan/qey_north/harolddunstan000.mp3", 1944438004, 3707588738)
  33. if GetQuestStep(Spawn,Cake)==1 then
  34. Dialog.AddOption("I've actually got a bundle of baked goods from Tibby Copperpot for you.","Delivered")
  35. end
  36. Dialog.AddOption("Sure. I'll take a look at what you have.")
  37. Dialog.AddOption("I am not very thirsty right now. ")
  38. Dialog.Start()
  39. end
  40. function Delivered(NPC, Spawn)
  41. FaceTarget(NPC, Spawn)
  42. Dialog.New(NPC, Spawn)
  43. Dialog.AddDialog("Splended! These pastries are just the ticket! These tasty treats will go nicely with all my brews. Thank you for this kind deed.")
  44. Dialog.AddVoiceover("voiceover/english/harold_dunstan/qey_north/harolddunstan001.mp3", 3012893406, 2195271549)
  45. PlayFlavor(NPC,"","","smile",0,0,Spawn)
  46. Dialog.AddOption("It was no problem","JobDone")
  47. Dialog.Start()
  48. end
  49. function JobDone(NPC, Spawn)
  50. FaceTarget(NPC, Spawn)
  51. SetStepComplete(Spawn,Cake, 1)
  52. end