GnorFarven.lua 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. --[[
  2. Script Name : SpawnScripts/Graystone/GnorFarven.lua
  3. Script Purpose : Gnor Farven
  4. Script Author : Scatman
  5. Script Date : 2009.10.05
  6. Script Notes :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericVoiceOvers.lua")
  9. local DWARF_MENTOR_QUEST_2 = 285
  10. function spawn(NPC)
  11. SetInfoStructString(NPC, "action_state", "drinking_idle")
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function hailed(NPC, Spawn)
  17. FaceTarget(NPC, Spawn)
  18. conversation = CreateConversation()
  19. GenericHail(NPC, Spawn)
  20. if HasQuest(Spawn, DWARF_MENTOR_QUEST_2) and not QuestStepIsComplete(Spawn, DWARF_MENTOR_QUEST_2, 2) then
  21. LikinTheViewAreYa(NPC, Spawn, conversation)
  22. else
  23. Say(NPC, "Sorry, it's near impossible for me to drink and talk at the same time.", Spawn)
  24. end
  25. end
  26. function LikinTheViewAreYa(NPC, Spawn, conversation)
  27. AddConversationOption(conversation, "Mav made some of her family recipe.", "dlg_17_1")
  28. StartConversation(conversation, NPC, Spawn, "Likin' the view, are ya? Hah hah!")
  29. end
  30. function dlg_17_1(NPC, Spawn)
  31. FaceTarget(NPC, Spawn)
  32. conversation = CreateConversation()
  33. AddConversationOption(conversation, "Well, prepare to find out. I have some of the brew right here.", "dlg_17_2")
  34. StartConversation(conversation, NPC, Spawn, "So she finally made good on her promise! It's about time. I'm going to have to schedule an appointment with her, cause I'm sure that's what it'll take to try some of this magical brew of hers. You know she says it can knock an ogre on 'is back, I dun' believe it though.")
  35. end
  36. function dlg_17_2(NPC, Spawn)
  37. FaceTarget(NPC, Spawn)
  38. conversation = CreateConversation()
  39. AddConversationOption(conversation, "Here you go.", "dlg_17_3")
  40. StartConversation(conversation, NPC, Spawn, "Oy! Fill 'er up then why don't ya! If it's half as good as Mav describes it it'll have been worth the wait.")
  41. end
  42. function dlg_17_3(NPC, Spawn)
  43. FaceTarget(NPC, Spawn)
  44. conversation = CreateConversation()
  45. PlayAnimation(NPC,11422)
  46. AddConversationOption(conversation, "How is it?", "dlg_17_4")
  47. StartConversation(conversation, NPC, Spawn, "Hold your chairs 'cause here I go!")
  48. end
  49. function dlg_17_4(NPC, Spawn)
  50. SetStepComplete(Spawn, DWARF_MENTOR_QUEST_2, 2)
  51. -- knockeddowntoknees
  52. SpawnSet(NPC, "visual_state", 11764)
  53. AddTimer(NPC, 3000, "RemoveVisualState")
  54. FaceTarget(NPC, Spawn)
  55. conversation = CreateConversation()
  56. AddConversationOption(conversation, "You're welcome.")
  57. StartConversation(conversation, NPC, Spawn, "Oooooh-wee, that'll make ya warm at night. She was right about it. I can't wait until she goes into business. Best brew this side of Kaladim. Hah, no offense, Coppershot! Thanks for bringing it to me!")
  58. end
  59. function RemoveVisualState(NPC)
  60. SpawnSet(NPC, "visual_state", 0)
  61. end