StatiaViatrix.lua 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. --[[
  2. Script Name : SpawnScripts/BeggarsCourt/StatiaViatrix.lua
  3. Script Purpose : Statia Viatrix
  4. Script Author : torsten
  5. Script Date : 2022.07.18
  6. Script Notes : Auto-Generated Conversation from PacketParser Data
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericEcologyVoiceOvers.lua")
  9. local TimeCheck = false -- used to delay between hail uses
  10. function spawn(NPC)
  11. SetInfoStructString(NPC, "action_state", "ponder")
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function hailed(NPC, Spawn)
  17. if GetFactionAmount(Spawn,12) <0 then
  18. FaceTarget(NPC, Spawn)
  19. FactionChecking(NPC, Spawn, faction)
  20. else
  21. if TimeCheck == false then -- checks timer
  22. TimeCheck = true -- turns on timer to stop player spamming
  23. AddTimer(NPC,2500,"ResetTimer")
  24. FaceTarget(NPC, Spawn)
  25. Talk(NPC, Spawn)
  26. end
  27. end
  28. end
  29. function ResetTimer(NPC) -- resets hail timer after initial use
  30. TimeCheck = false
  31. end
  32. function Talk(NPC, Spawn)
  33. local choice = MakeRandomInt(1,5)
  34. if choice == 1 then
  35. PlayFlavor(NPC, "voiceover/english/human_eco_evil_coalitionoftradesfolke/ft/eco/evil/human_female_eco_evil_coalitionoftradesfolke_hail_gf_bee46698.mp3", "Those Arcane Scientists just spend way too much time studying in their confines. They need to get out more.", "", 1647416091, 3708087662, Spawn, 0)
  36. elseif choice == 2 then
  37. PlayFlavor(NPC, "voiceover/english/human_eco_evil_coalitionoftradesfolke/ft/eco/evil/human_female_eco_evil_coalitionoftradesfolke_hail_gf_2b5f7257.mp3", "The Coalition of Tradesfolke sure knows how to make coins fall into their hands.", "", 156316039, 999118411, Spawn, 0)
  38. elseif choice == 3 then
  39. PlayFlavor(NPC, "voiceover/english/human_eco_evil_coalitionoftradesfolke/ft/eco/evil/human_female_eco_evil_coalitionoftradesfolke_hail_gf_2747c168.mp3", "The Freeport Militia is a group of hired thugs that are only interested in their own benefits.", "", 1417468938, 1166342004, Spawn, 0)
  40. elseif choice == 4 then
  41. PlayFlavor(NPC, "voiceover/english/human_eco_evil_coalitionoftradesfolke/ft/eco/evil/human_female_eco_evil_coalitionoftradesfolke_hail_gf_276a219b.mp3", "The souls of the Dismal Rage priests are so dark that their pale look will make you sick before they can ever heal you.", "", 3986145161, 2347838996, Spawn, 0)
  42. elseif choice == 5 then
  43. PlayFlavor(NPC, "voiceover/english/human_eco_evil_coalitionoftradesfolke/ft/eco/evil/human_female_eco_evil_coalitionoftradesfolke_hail_gf_15b4266c.mp3", "The Seafury Buccaneers don't seem too bright. They probably lost their ability to think from travelling the seas for too long.", "", 1874743335, 3247477803, Spawn, 0)
  44. end
  45. end