CaptainTyreth.lua 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. --[[
  2. Script Name : CaptainTyreth.lua
  3. Script Purpose : Captain Tyreth
  4. Script Author : vo1d
  5. Script Date : 10/12/2019
  6. Script Notes : WIP, Tyreth isn't functioning yet.
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. -- Quest ID's
  10. local TheFinalAssault = 367
  11. function spawn(NPC)
  12. SetPlayerProximityFunction(NPC, 10, "InRange", "LeaveRange")
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function InRange(NPC, Spawn)
  18. end
  19. function LeaveRange(NPC, Spawn)
  20. end
  21. function hailed(NPC, Spawn)
  22. -- Face the player
  23. FaceTarget(NPC, Spawn)
  24. -- Create a conversation
  25. Conversation = CreateConversation()
  26. -- Dialogue
  27. AddConversationOption(Conversation, "That's me.", "dlg_2")
  28. AddConversationOption(Conversation, "I need to be leaving.")
  29. -- Start conversation
  30. StartConversation(Conversation, NPC, Spawn, "Hahaha! The attack has begun and the enemy shall fall! You must be " .. GetName(Spawn) .. ", here to take part in the festivities.")
  31. end
  32. function dlg_2(NPC, Spawn)
  33. FaceTarget(NPC, Spawn)
  34. Dialog.New(NPC, Spawn)
  35. Dialog.AddDialog("Ah, you were the one who coerced these sentries out of the area before the attack. Nicely done! It is time to complete our domination. The Militia are advancing and beginning to clear the area. It is time to strike, quickly!")
  36. Dialog.AddVoiceover("voiceover/english/tutorial_revamp/captain_tyreth/tutorial_island02_evil_revamp/quests/citizenship/captaintyreth/captaintyreth002.mp3", 3182304037, 930301833)
  37. Dialog.AddOption("What must I do?", "dlg_3")
  38. Dialog.Start()
  39. end
  40. function dlg_3(NPC, Spawn)
  41. FaceTarget(NPC, Spawn)
  42. Dialog.New(NPC, Spawn)
  43. SummonItem(Spawn, 48997, 1)
  44. Dialog.AddDialog("Take this torch. Work your way in and set fire to two of the nearby tents. Others have begun the razing as well. If another's flame fails, make sure you finish the job. This island will soon be ours!")
  45. Dialog.AddVoiceover("voiceover/english/tutorial_revamp/captain_tyreth/tutorial_island02_evil_revamp/quests/citizenship/captaintyreth/captaintyreth003.mp3", 3312554119, 4055641204)
  46. Dialog.AddOption("I'll burn the tents of the Qeynosians.")
  47. SetStepComplete(Spawn, TheFinalAssault, 1)
  48. Dialog.Start()
  49. end