HunterVannil.lua 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. --[[
  2. Script Name : SpawnScripts/WillowWood/HunterVannil.lua
  3. Script Purpose : Hunter Vannil
  4. Script Author : Scatman
  5. Script Date : 2009.09.27
  6. Script Notes : This spawn speaks Ayr'Dal
  7. --]]
  8. local QUEST_1 = 222
  9. function spawn(NPC)
  10. ProvidesQuest(NPC, QUEST_1)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function hailed(NPC, Spawn)
  16. FaceTarget(NPC, Spawn)
  17. conversation = CreateConversation()
  18. if HasCompletedQuest(Spawn, QUEST_1) then
  19. local choice = math.random(1, 2)
  20. if choice == 1 then
  21. Say(NPC, "Come to get a better vantage point of the village, friend?", Spawn)
  22. elseif choice == 2 then
  23. PlayFlavor(NPC, "voiceover/english/hunter_vannil/qey_village05/huntervannil000.mp3", "", "", 1807378459, 3962910976, Spawn)
  24. Say(NPC, "Good day to you, friend. So you too have an interest in keeping an eye on who comes and goes out of these gates?", Spawn)
  25. end
  26. else
  27. if HasQuest(Spawn, QUEST_1) then
  28. if GetQuestStep(Spawn, QUEST_1) == 2 then
  29. AddConversationOption(conversation, "I have slain the adders.", "AddersSlain")
  30. end
  31. elseif GetLevel(Spawn) >= 2 then
  32. AddConversationOption(conversation, "Where does that gate go?", "dlg_1_1")
  33. end
  34. PlayFlavor(NPC, "voiceover/english/hunter_vannil/qey_village05/huntervannil000.mp3", "", "", 1807378459, 3962910976, Spawn)
  35. AddConversationOption(conversation, "Not really, I am just doing a bit of exploring. ")
  36. StartConversation(conversation, NPC, Spawn, "Good day to you, friend. So you too have an interest in keeping an eye on who comes and goes out of these gates?")
  37. end
  38. end
  39. function dlg_1_1(NPC, Spawn)
  40. FaceTarget(NPC, Spawn)
  41. conversation = CreateConversation()
  42. PlayFlavor(NPC, "voiceover/english/hunter_vannil/qey_village05/huntervannil001.mp3", "", "", 929186001, 4080341564, Spawn)
  43. AddConversationOption(conversation, "I'm up for a little snake hunting.", "OfferQuest1")
  44. AddConversationOption(conversation, "I'm sorry, but I'm not up to snake hunting.")
  45. StartConversation(conversation, NPC, Spawn, "That gate leads to the Elddar and the other gate leads to the Forest Ruins. Many young adventurers journey through the gates testing their mettle against the dangerous creatures that inhabit the area. Say, you seem courageous... would you help rid the area of rock adders? The creatures are a lethal threat to our people!")
  46. end
  47. function OfferQuest1(NPC, Spawn)
  48. FaceTarget(NPC, Spawn)
  49. OfferQuest(NPC, Spawn, QUEST_1)
  50. end
  51. function dlg_23_1(NPC, Spawn)
  52. FaceTarget(NPC, Spawn)
  53. conversation = CreateConversation()
  54. PlayFlavor(NPC, "voiceover/english/hunter_vannil/qey_village05/huntervannil001.mp3", "", "", 929186001, 4080341564, Spawn)
  55. AddConversationOption(conversation, "I'm up for a little snake hunting.", "dlg_23_2")
  56. AddConversationOption(conversation, "I'm sorry, but I'm not up to snake hunting.")
  57. StartConversation(conversation, NPC, Spawn, "That gate leads to the Elddar and the other gate leads to the Forest Ruins. Many young adventurers journey through the gates testing their mettle against the dangerous creatures that inhabit the area. Say, you seem courageous... would you help rid the area of rock adders? The creatures are a lethal threat to our people!")
  58. end
  59. function dlg_23_2(NPC, Spawn)
  60. FaceTarget(NPC, Spawn)
  61. conversation = CreateConversation()
  62. PlayFlavor(NPC, "voiceover/english/hunter_vannil/qey_village05/huntervannil002.mp3", "", "", 2784879734, 2610513967, Spawn)
  63. AddConversationOption(conversation, "Thanks, this shouldn't be too difficult a hunt.", "dlg_23_3")
  64. StartConversation(conversation, NPC, Spawn, "Good. Killing the deadly adders shall make our village a safer place. Good luck on your hunt. Please be careful.")
  65. end
  66. function AddersSlain(NPC, Spawn)
  67. SetStepComplete(Spawn, QUEST_1, 2)
  68. FaceTarget(NPC, Spawn)
  69. conversation = CreateConversation()
  70. AddConversationOption(conversation, "You're welcome.")
  71. StartConversation(conversation, NPC, Spawn, "You killed the rock adders! On behalf of our village, I thank you for carrying out this dangerous quest.")
  72. end