NiaJaja.lua 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. --[[
  2. Script Name : SpawnScripts/Nettleville/NiaJaja.lua
  3. Script Purpose : Nia Jaja
  4. Script Author : Dorbin
  5. Script Date : 06.25.2022
  6. Script Notes : Has Kerran Language check
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. dofile("SpawnScripts/Generic/UnknownLanguage.lua")
  10. function spawn(NPC)
  11. SetPlayerProximityFunction(NPC, 7, "InRange", "LeaveRange")
  12. ProvidesQuest(NPC,5598)
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function InRange(NPC,Spawn)
  18. if not HasQuest(Spawn, 5598) and not HasCompletedQuest(Spawn,5598)then
  19. if math.random(1,100)<=85 then
  20. if not HasLanguage(Spawn,13)then
  21. FaceTarget(NPC, Spawn)
  22. Garbled(NPC,Spawn)
  23. else
  24. PlayFlavor(NPC, "voiceover/english/nia_jaja/qey_village01/qey_village01_nia_jaja_callout1_87e08206.mp3", "... and then she has the gall to say my coat rrreminders her of a common hyena! I can't stand that woman! I can't face her again! Oh, I need someone to help me.", "", 1998825354, 2680772618, Spawn,13)
  25. end
  26. end
  27. end
  28. end
  29. function hailed(NPC, Spawn)
  30. FaceTarget(NPC, Spawn)
  31. if GetFactionAmount(Spawn,11)<0 then
  32. PlayFlavor(NPC, "", "", "shakefist", 0, 0, Spawn)
  33. else
  34. if HasCompletedQuest(Spawn,5598)then
  35. PlayFlavor(NPC, "voiceover/english/nia_jaja/qey_village01/qey_village01_nia_jaja_multhail1_ab7bd6d4.mp3", "I simply can't face her! Can't you see I'm angry; I've no time to chat with you!", "", 1436884292, 4259898399, Spawn,13)
  36. else
  37. if not HasLanguage(Spawn,13)then
  38. Garbled(NPC,Spawn)
  39. PlayFlavor(NPC,"","","noway",0,0,Spawn)
  40. else
  41. FaceTarget(NPC, Spawn)
  42. Dialog.New(NPC, Spawn)
  43. PlayFlavor(NPC, "", "", "no", 0, 0, Spawn)
  44. Dialog.AddDialog("... and then she has the gall to say my coat rrremindered her of a common hyena!")
  45. Dialog.AddVoiceover("voiceover/english/nia_jaja/qey_village01/niajaja000.mp3", 2194298502, 3471338727)
  46. Dialog.AddLanguage(13)
  47. if not HasCompletedQuest (Spawn, 5598) and not HasQuest (Spawn, 5598) then
  48. Dialog.AddOption("Excuse me, but who said that?", "Helping")
  49. end
  50. if GetQuestStep (Spawn, 5598)==2 then
  51. Dialog.AddOption("Marjani is still hanging around the scribe shop.","Delivered")
  52. end
  53. Dialog.AddOption("Sorry, I'm just passing through.")
  54. Dialog.Start()
  55. end
  56. end
  57. end
  58. end
  59. function Helping(NPC, Spawn)
  60. FaceTarget(NPC, Spawn)
  61. Dialog.New(NPC, Spawn)
  62. PlayFlavor(NPC, "", "", "frustrated", 0, 0, Spawn)
  63. Dialog.AddDialog("Oh, it was that minx Marrrjani Kenan! First she insults my knowledge of magic and then my gorgeous coat! Would you help me? I need to know if Marjani is still in the scrrribe shop. I don't want to return to work until that SHREW is gone!")
  64. Dialog.AddVoiceover("voiceover/english/nia_jaja/qey_village01/niajaja001.mp3", 3841131398, 2599787330)
  65. Dialog.AddLanguage(13)
  66. Dialog.AddOption("I can go check for you.", "QuestBegin")
  67. Dialog.AddOption("That is unfortunate. Sorry, but I'm busy.")
  68. Dialog.Start()
  69. end
  70. function QuestBegin (NPC, Spawn)
  71. FaceTarget(NPC, Spawn)
  72. OfferQuest(NPC, Spawn, 5598)
  73. end
  74. function Delivered(NPC, Spawn)
  75. FaceTarget(NPC, Spawn)
  76. Dialog.New(NPC, Spawn)
  77. PlayFlavor(NPC, "", "", "stare", 0, 0, Spawn)
  78. Dialog.AddDialog("She was still there?! I guess I won't be going back today. I want to claw- her- eyes- out!")
  79. Dialog.AddVoiceover("voiceover/english/nia_jaja/qey_village01/niajaja003.mp3", 473886489, 3909124821)
  80. Dialog.AddLanguage(13)
  81. Dialog.AddOption("Sorry to be the barer of bad news!", "QuestDone")
  82. Dialog.AddOption("...I'll just be... over there...", "QuestDone")
  83. Dialog.Start()
  84. end
  85. function QuestDone(NPC, Spawn)
  86. SetStepComplete(Spawn, 5598, 2)
  87. end