9
3

Conthar.lua 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. --[[
  2. Script Name : SpawnScripts/Freeport/Conthar.lua
  3. Script Author : Premierio015
  4. Script Date : 2020.07.18 09:07:17
  5. Script Purpose :
  6. :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericGuardVoiceOvers.lua")
  9. function spawn(NPC)
  10. movement_loop_start(NPC)
  11. end
  12. function movement_loop_start(NPC)
  13. MoveToLocation(NPC, 35.67, -11.84, 194.84, 2)
  14. MoveToLocation(NPC, 38.68, -12.09, 184.16, 2)
  15. MoveToLocation(NPC, 50.30, -12.09, 178.56, 2)
  16. MoveToLocation(NPC, 61.03, -12.10, 161.16, 2, "heading")
  17. end
  18. function heading(NPC)
  19. SetHeading(NPC, 337.74)
  20. AddTimer(NPC, 10000, "movement_loop_continue", 1)
  21. end
  22. function heading2(NPC)
  23. SetHeading(NPC, 179.10)
  24. AddTimer(NPC, 10000, "movement_loop_start", 1)
  25. end
  26. function movement_loop_continue(NPC)
  27. MoveToLocation(NPC, 56.11, -12.08, 179.73, 2)
  28. MoveToLocation(NPC, 61.33, -12.09, 189.03, 2)
  29. MoveToLocation(NPC, 62.46, -12.09, 195.40, 2)
  30. MoveToLocation(NPC, 58.07, -12.09, 209.48, 2)
  31. MoveToLocation(NPC, 60.92, -12.10, 230.18, 2, "heading2")
  32. end
  33. function hailed(NPC, Spawn)
  34. FaceTarget(NPC, Spawn)
  35. GenericGuardHail(NPC, Spawn, Faction)
  36. local choice = MakeRandomInt(1, 2)
  37. if choice == 1 then
  38. AddTimer(NPC, 10000, "movement_loop_start", 1)
  39. else
  40. AddTimer(NPC, 10000, "movement_loop_continue", 1)
  41. end
  42. end
  43. function respawn(NPC)
  44. spawn(NPC)
  45. end