afallenassassin.lua 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. --[[
  2. Script Name : SpawnScripts/QueensColony/afallenassassin.lua
  3. Script Purpose : Path to doom, and drop skull when killed by player
  4. Script Author : Jabantiz
  5. Script Date : 9/11/2016
  6. Script Notes : <special-instructions>
  7. --]]
  8. function spawn(NPC)
  9. MovementLoopAddLocation(NPC, -125.5, 4.64, -50.29, 4)
  10. MovementLoopAddLocation(NPC, -132.23, 4.36, -63.2, 4)
  11. MovementLoopAddLocation(NPC, -133.43, 4.37, -88.26, 4)
  12. MovementLoopAddLocation(NPC, -110.11, 4.29, -101.71, 4)
  13. MovementLoopAddLocation(NPC, -97.02, 4.24, -116.82, 4)
  14. MovementLoopAddLocation(NPC, -81.65, 4.13, -120.89, 4)
  15. MovementLoopAddLocation(NPC, -70.74, 4.09, -133.39, 4)
  16. MovementLoopAddLocation(NPC, -57.57, 2.24, -135.21, 4)
  17. MovementLoopAddLocation(NPC, -51.81, 2.03, -153.28, 4, 60)
  18. end
  19. function respawn(NPC)
  20. spawn(NPC)
  21. end
  22. function death(NPC, Spawn)
  23. if IsPlayer(Spawn) then
  24. local chance = math.random(1, 100)
  25. if chance <= 35 then
  26. local skull = SpawnMob(GetZone(Spawn), 2530192, false, GetX(NPC), GetY(NPC), GetZ(NPC))
  27. if skull ~= nil then
  28. SpawnSet(skull, "expire", "1000")
  29. end
  30. end
  31. end
  32. end