9
3

widgetbox7.lua 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. --[[
  2. Script Name : SpawnScripts/SunkenCity_Classic/widgetbox7.lua
  3. Script Author : Dorbin
  4. Script Date : 2023.11.03 01:11:48
  5. Script Purpose :
  6. :
  7. --]]
  8. local LukursAntiques = 374
  9. function spawn(NPC)
  10. SetRequiredQuest(NPC, LukursAntiques, 1)
  11. SetRequiredQuest(NPC, LukursAntiques, 2)
  12. SetRequiredQuest(NPC, LukursAntiques, 3)
  13. SetTempVariable(NPC,"Mask","false")
  14. AddTimer(NPC,2000,"MaskCheck")
  15. end
  16. function casted_on(NPC, Spawn, SpellName)
  17. if SpellName == 'Search' then
  18. if GetTempVariable(NPC,"Mask")=="true" and GetQuestStepProgress(Spawn,LukursAntiques,1)==0 then --DawnMask
  19. SetStepComplete(Spawn, LukursAntiques, 1)
  20. SendMessage(Spawn,"You find a Blood Mask inside the barrel.")
  21. else
  22. SendMessage(Spawn,"You only see the remains of rotten produce in this barrel.")
  23. end
  24. end
  25. end
  26. function MaskCheck(NPC)
  27. local zone = GetZone(NPC)
  28. local Muck1 = GetSpawnByLocationID(zone, 133787343)
  29. local Muck2 = GetSpawnByLocationID(zone, 133787394)
  30. if Muck2 == nil and Muck1 ~= nil
  31. then
  32. SetTempVariable(NPC,"Mask","true")
  33. else
  34. end
  35. end
  36. function respawn(NPC)
  37. spawn(NPC)
  38. end