9
3

aDervishcraftsman.lua 923 B

123456789101112131415161718192021222324252627282930313233
  1. --[[
  2. Script Name : SpawnScripts/Commonlands/aDervishcraftsman.lua
  3. Script Author : Premierio015
  4. Script Date : 2021.05.19 04:05:06
  5. Script Purpose :
  6. :
  7. --]]
  8. require "SpawnScripts/Generic/NPCModule"
  9. function spawn(NPC, Spawn)
  10. NPCModule(NPC, Spawn)
  11. SetPlayerProximityFunction(NPC, 10, "InRange")
  12. end
  13. function InRange(NPC, Spawn)
  14. local choice = MakeRandomInt(1, 3)
  15. if choice == 1 then
  16. PlayFlavor(NPC, "", "This is Dervish territory. Leave while you still can.", "brandish", 0, 0, Spawn)
  17. elseif choice == 2 then
  18. PlayFlavor(NPC, "", "I only do business with Dervs. Go away!", "no", 0, 0, Spawn)
  19. else
  20. PlayFlavor(NPC, "", "Who would ever think that a Smithson would end up being an evil pounder to the bandits", "whome", 0, 0, Spawn)
  21. end
  22. end
  23. function hailed(NPC, Spawn)
  24. FaceTarget(NPC, Spawn)
  25. end
  26. function respawn(NPC)
  27. spawn(NPC)
  28. end