atreasuerchestCyn.lua 902 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. --[[
  2. Script Name : SpawnScripts/FarJourneyFreeport/atreasuerchest.lua
  3. Script Author : Cynnar
  4. Script Date : 2020.05.16 07:05:28
  5. Script Purpose :
  6. :
  7. --]]
  8. local TasksaboardtheFarJourney = 524
  9. local SmallBag = 20902
  10. local WaulonsHat = 15354
  11. local ThreadbareTunic = 185427
  12. function spawn(NPC)
  13. end
  14. function casted_on(NPC, Spawn, SpellName)
  15. if HasQuest(Spawn, TasksaboardtheFarJourney) then
  16. if GetQuestStep(Spawn, TasksaboardtheFarJourney) == 2 then
  17. SpawnSet(NPC, "visual_state", 11903)
  18. GiveLoot(NPC, Spawn, 0, 20902, 15354, 185427)
  19. else
  20. SpawnSet(NPC, "visual_state", 11903)
  21. SendMessage(Spawn, "This box is empty", "white")
  22. end
  23. end
  24. end
  25. function passoutloot(NPC, Spawn)
  26. GiveLoot(NPC, Spawn, 0, SmallBag, WaulonsHat, ThreadbareTunic)
  27. Say(NPC, "Past give loot")
  28. end
  29. function respawn(NPC)
  30. end