TrapperBorgus.lua 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. --[[
  2. Script Name : SpawnScripts/ThunderingSteppes/TrapperBorgus.lua
  3. Script Author : Jabantiz
  4. Script Date : 2014.07.03 06:07:51
  5. Script Purpose :
  6. :
  7. --]]
  8. local HuntingForTrapperBorgus = 98
  9. function spawn(NPC)
  10. SetPlayerProximityFunction(NPC, 20, "InRange")
  11. ProvidesQuest(NPC, HuntingForTrapperBorgus)
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function InRange(NPC, Spawn)
  17. if not HasQuest(Spawn, HuntingForTrapperBorgus) then
  18. if HasCompletedQuest(Spawn, HuntingForTrapperBorgus) then
  19. PlayFlavor(NPC, "voiceover/english/trapper_borgus/steppes/030_dwarf_trapper_borgus_aoi_callout_familiar_75373ef2.mp3", "Ah! There you are, I need yer help again!", "wave", 3299608738, 3594130452, Spawn)
  20. else
  21. PlayFlavor(NPC, "voiceover/english/trapper_borgus/steppes/030_dwarf_trapper_borgus_aoi_callout_unfamiliar_93226f1b.mp3", "Oh me achin' back! Give an old dwarf a hand?", "wince", 4014576750, 2294200697, Spawn)
  22. end
  23. end
  24. end
  25. function hailed(NPC, Spawn)
  26. FaceTarget(NPC, Spawn)
  27. conversation = CreateConversation()
  28. if HasQuest(Spawn, HuntingForTrapperBorgus) then
  29. -- Has the quest
  30. if GetQuestStep(Spawn, HuntingForTrapperBorgus) == 1 then
  31. -- Hasn't finished the quest yet
  32. PlayFlavor(NPC, "voiceover/english/trapper_borgus/steppes/trapper_borgus003.mp3", "", "", 2061866687, 623475610, Spawn)
  33. AddConversationOption(conversation, "No problem.")
  34. StartConversation(conversation, NPC, Spawn, "That's not enough beasts to fill me bags! I need more Steppes beasts for my provisions!")
  35. elseif GetQuestStep(Spawn, HuntingForTrapperBorgus) == 2 then
  36. -- Finished and turning the quest in
  37. SetStepComplete(Spawn, HuntingForTrapperBorgus, 2)
  38. PlayFlavor(NPC, "voiceover/english/trapper_borgus/steppes/trapper_borgus004.mp3", "", "", 2882844739, 4151927708, Spawn)
  39. AddConversationOption(conversation, "Sure.", "dlg_2_1")
  40. AddConversationOption(conversation, "Not right now.")
  41. StartConversation(conversation, NPC, Spawn, "That should do the trick! Thank yeh for the help! Think you might want to get some more?")
  42. end
  43. else
  44. PlayFlavor(NPC, "voiceover/english/trapper_borgus/steppes/trapper_borgus001.mp3", "", "", 2091451215, 1918648250, Spawn)
  45. AddConversationOption(conversation, "Yes, I'll help you.", "dlg_1_1")
  46. AddConversationOption(conversation, "Sorry, I must get going.")
  47. StartConversation(conversation, NPC, Spawn, "Me family sent me out for provisions, and I hurt me back lifting me pack! I come from a family o' miners n' boulder bashers, I would never hear the end of it! Can you help me kill enough beasts to get the provisions I need?")
  48. end
  49. end
  50. function dlg_1_1(NPC, Spawn)
  51. OfferQuest(NPC, Spawn, HuntingForTrapperBorgus)
  52. end
  53. function dlg_2_1(NPC, Spawn)
  54. SetTempVariable(Spawn, "RepeatHuntingForTrapperBorgus", "true")
  55. OfferQuest(NPC, Spawn, HuntingForTrapperBorgus)
  56. end