Laena.lua 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. --[[
  2. Script Name : SpawnScripts/OutpostOverlord/Laena.lua
  3. Script Purpose : Laena
  4. Script Author : John Adams
  5. Script Date : 2008.09.23
  6. Script Notes : Auto-Generated Conversation from PacketParser Data
  7. Modified Script Notes : Added SpawnAccess
  8. Modified by : premierio015
  9. --]]
  10. local TheTunarianPlot = 491
  11. function spawn(NPC)
  12. AddSpawnAccess(NPC, NPC)
  13. SetPlayerProximityFunction(NPC, 20, "SpawnAccess", "SpawnAccess")
  14. end
  15. function SpawnAccess(NPC, Spawn)
  16. if GetQuestStep(Spawn, TheTunarianPlot) == 6 then
  17. AddSpawnAccess(NPC, Spawn)
  18. else
  19. RemoveSpawnAccess(NPC, Spawn)
  20. end
  21. end
  22. function aggro(NPC, Spawn)
  23. FaceTarget(NPC, Spawn)
  24. choice = math.random(1,3)
  25. if choice == 1 then
  26. PlayFlavor(NPC, "", "For the Queen!", "combat_enter", 1689589577, 4560189, Spawn)
  27. elseif choice == 2 then
  28. PlayFlavor(NPC, "", "Die, Freeport scum!", "threaten", 1689589577, 4560189, Spawn)
  29. elseif choice == 3 then
  30. PlayFlavor(NPC, "", "To the gray fields with them!", "", 1689589577, 4560189, Spawn)
  31. end
  32. end