9
3

BurmGrunthor.lua 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. --[[
  2. Script Name : SpawnScripts/Everfrost/BurmGrunthor.lua
  3. Script Author : Flunklesnarkin
  4. Script Date : 2015.09.03 10:09:57
  5. Script Purpose :
  6. :
  7. --]]
  8. local Fish_For_Grunther = 136
  9. function spawn(NPC)
  10. ProvidesQuest(NPC, Fish_For_Grunther)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function hailed(NPC, Spawn)
  16. FaceTarget(NPC, Spawn)
  17. if GetLevel(Spawn) < 41 then
  18. UnderLevel_Chat(NPC, Spawn)
  19. else
  20. if HasQuest(Spawn, Fish_For_Grunther) == false and HasCompletedQuest(Spawn, Fish_For_Grunther) == false then
  21. Quest1Chat_1(NPC, Spawn)
  22. elseif GetQuestStep(Spawn, Fish_For_Grunther) == 1 then
  23. if HasCompletedQuest(Spawn, Fish_For_Grunther) == true then
  24. Quest1Chat_3(NPC, Spawn)
  25. else
  26. Quest1Chat_7(NPC, Spawn)
  27. end
  28. elseif GetQuestStep(Spawn, Fish_For_Grunther) == 2 then
  29. if HasCompletedQuest(Spawn, Fish_For_Grunther) == true then
  30. Quest1Chat_8(NPC, Spawn)
  31. else
  32. Quest1Chat_5(NPC, Spawn)
  33. end
  34. elseif HasQuest(Spawn, Fish_For_Grunther) == false and HasCompletedQuest(Spawn, Fish_For_Grunther) == true then
  35. Quest1Chat_4(NPC, Spawn)
  36. end
  37. end
  38. end
  39. function UnderLevel_Chat(NPC, Spawn)
  40. Say(NPC, "Just me and fishes out here sometimes. Just me and the fishes.")
  41. end
  42. function Quest1Chat_1(NPC, Spawn)
  43. FaceTarget(NPC, Spawn)
  44. conversation = CreateConversation()
  45. AddConversationOption(conversation, "Oh?", "Quest1Chat_2")
  46. StartConversation(conversation, NPC, Spawn, "Arh! The fish just aren't biting!")
  47. end
  48. function Quest1Chat_2(NPC, Spawn)
  49. FaceTarget(NPC, Spawn)
  50. conversation = CreateConversation()
  51. AddConversationOption(conversation, "Perhaps I could fish some for you?", "Offer_Fish_For_Grunther")
  52. AddConversationOption(conversation, "Sounds like you should work on your fishing skills.")
  53. StartConversation(conversation, NPC, Spawn, "Nay, I've been at it for hours, but nuthin'. And I've mouths to feed...")
  54. end
  55. function Quest1Chat_3(NPC, Spawn)
  56. FaceTarget(NPC, Spawn)
  57. conversation = CreateConversation()
  58. AddConversationOption(conversation, "I do not.")
  59. StartConversation(conversation, NPC, Spawn, "Have ye the fish?")
  60. end
  61. function Quest1Chat_4(NPC, Spawn)
  62. FaceTarget(NPC, Spawn)
  63. conversation = CreateConversation()
  64. AddConversationOption(conversation, "I most certainly would.", "Offer_Fish_For_Grunther")
  65. AddConversationOption(conversation, "Nah, I've got better things to do with my time.")
  66. StartConversation(conversation, NPC, Spawn, "I could always use some'mere fish if ye'd be up fer it.")
  67. end
  68. function Quest1Chat_5(NPC, Spawn)
  69. SetStepComplete(Spawn, Fish_For_Grunther, 2)
  70. FaceTarget(NPC, Spawn)
  71. conversation = CreateConversation()
  72. AddConversationOption(conversation, "Yes, here's all your fish." , "Quest1Chat_6")
  73. StartConversation(conversation, NPC, Spawn, "Is that the smell of fish on ye?")
  74. end
  75. function Quest1Chat_6(NPC, Spawn)
  76. FaceTarget(NPC, Spawn)
  77. conversation = CreateConversation()
  78. AddConversationOption(conversation, "I am glad to have helped.")
  79. StartConversation(conversation, NPC, Spawn, "Ahh, a fine batch if I've ever seen it. Thank ye.")
  80. end
  81. function Quest1Chat_7(NPC, Spawn)
  82. FaceTarget(NPC, Spawn)
  83. conversation = CreateConversation()
  84. AddConversationOption(conversation, "No, must just be all the adventuring I've been doing...")
  85. StartConversation(conversation, NPC, Spawn, "Is that the smell of fish on ye?")
  86. end
  87. function Quest1Chat_8(NPC, Spawn)
  88. SetStepComplete(Spawn, Fish_For_Grunther, 2)
  89. FaceTarget(NPC, Spawn)
  90. conversation = CreateConversation()
  91. AddConversationOption(conversation, "I do." , "Quest1Chat_9")
  92. StartConversation(conversation, NPC, Spawn, "Have ye the fish?")
  93. end
  94. function Quest1Chat_9(NPC, Spawn)
  95. FaceTarget(NPC, Spawn)
  96. conversation = CreateConversation()
  97. AddConversationOption(conversation, "You are most welcome.")
  98. StartConversation(conversation, NPC, Spawn, "A blessing! Aye, I can call ye nay but a blessing.")
  99. end
  100. function Offer_Fish_For_Grunther(NPC, Spawn)
  101. if HasQuest(Spawn, Fish_For_Grunther) == false and HasCompletedQuest(Spawn, Fish_For_Grunther) == false then
  102. OfferQuest(NPC, Spawn, Fish_For_Grunther)
  103. FaceTarget(NPC, Spawn)
  104. conversation = CreateConversation()
  105. AddConversationOption(conversation, "Not to worry.")
  106. StartConversation(conversation, NPC, Spawn, "That'd truly be a blessing from the gods, thank ye.")
  107. elseif HasQuest(Spawn, Fish_For_Grunther) == false and HasCompletedQuest(Spawn, Fish_For_Grunther) == true then
  108. OfferQuest(NPC, Spawn, Fish_For_Grunther)
  109. FaceTarget(NPC, Spawn)
  110. conversation = CreateConversation()
  111. AddConversationOption(conversation, "You're welcome.")
  112. StartConversation(conversation, NPC, Spawn, "A fine young adventurer ye be, thank ye.")
  113. end
  114. end