Waulon.lua 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. require "SpawnScripts/Generic/DialogModule"
  2. function spawn(NPC)
  3. SetPlayerProximityFunction(NPC, 8, "InRange", "LeaveRange")
  4. end
  5. function InRange (NPC,player)
  6. step = GetQuestStep(player, 524)
  7. if step == 2 or step ==3 then
  8. PlayFlavor(NPC, "voiceover/english/waulon/boat_06p_tutorial02/walon_0_004.mp3", "Where's me hat? Needs me lucky hat!", "confused", 2688932325, 103225044, player, 0)
  9. end
  10. end
  11. function hailed(NPC, player)
  12. FaceTarget(NPC, player)
  13. if HasQuest(player, 524) == false or HasCompletedQuest(player, 524) == true then
  14. PlayFlavor(NPC, "voiceover/english/waulon/boat_06p_tutorial02/walon_0_008.mp3", "What? Can't ye see? Busy, away with ye!", "", 1608066875, 70639594)
  15. else
  16. step = GetQuestStep(player, 524)
  17. if step == 1 then
  18. -- InstructionWindowGoal(player,0)
  19. -- InstructionWindowClose(player)
  20. Dialog.New(NPC, player)
  21. Dialog.AddDialog("Wot? Oh, hey there, ye' startled me.")
  22. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_001.mp3", 814960513, 2301562586)
  23. Dialog.AddOption("Sorry about that.", "startled_me")
  24. Dialog.Start()
  25. elseif step == 2 then
  26. PlayFlavor(NPC, "", "", "frustrated", 2688932325, 103225044, player, 0)
  27. elseif step == 3 then
  28. Dialog.New(NPC, player)
  29. Dialog.AddDialog("Ah, me hat! Was worried. See, dis' hat gives me the luck.")
  30. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_005.mp3", 4097259098, 893296183)
  31. Dialog.AddOption("Glad to help!", "returned_hat")
  32. Dialog.Start()
  33. InstructionWindowGoal(player, 0)
  34. end
  35. end
  36. end
  37. function returned_hat(NPC, player)
  38. Dialog.New(NPC, player)
  39. Dialog.AddDialog("Now me is safe, thanks ta' ye. Here, take this charm. Ya' may find a use for it.")
  40. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_006.mp3", 316186630, 2628530085)
  41. Dialog.AddOption("Thanks, Waulon.", "received_charm")
  42. Dialog.Start()
  43. end
  44. function returned_hat(NPC, player)
  45. Dialog.New(NPC, player)
  46. Dialog.AddDialog("Well now, Ingrid o'er there, can show ya' the rest of the ship. Me needs ta' plot the course ta' the isles now.")
  47. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_007.mp3", 1973137904, 2648127610)
  48. Dialog.AddOption("Ok.", "finished_step_three")
  49. Dialog.Start()
  50. end
  51. function finished_step_three(NPC, player)
  52. SetStepComplete(player, 524, 3)
  53. end
  54. function startled_me(NPC, player)
  55. Dialog.New(NPC, player)
  56. Dialog.AddDialog("Can't seem ta' find me hat.")
  57. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_002.mp3", 1759807851, 3940656870)
  58. Dialog.AddOption("Do you need some help?", "help_find_hat")
  59. Dialog.Start()
  60. end
  61. function help_find_hat(NPC, player)
  62. chest = GetRandomSpawnByID(NPC, 270010)
  63. FaceTarget(NPC, chest)
  64. Dialog.New(NPC, player)
  65. Dialog.AddDialog("Sure! Me needs ya' ta' go lookie in them there boxes and if ye' find it, lets me know.")
  66. Dialog.AddVoiceover("voiceover/english/waulon/boat_06p_tutorial02/walon_0_003.mp3", 2072797774, 185252141)
  67. Dialog.AddOption("Ok.", "finished_step_one")
  68. Dialog.Start()
  69. end
  70. function finished_step_one(NPC, player)
  71. InstructionWindowGoal(player, 0)
  72. InstructionWindowClose(player)
  73. SetStepComplete(player, 524, 1)
  74. end
  75. function respawn(NPC)
  76. end