BlightoftheMorning.lua 832 B

123456789101112131415161718192021222324252627282930313233343536
  1. --[[
  2. Script Name : Spells/Commoner/BlightoftheMorning.lua
  3. Script Author : LordPazuzu
  4. Script Date : 2023.10.10 11:10:34
  5. Script Purpose :
  6. :
  7. --]]
  8. function cast(Caster, Target, DmgType, MinVal, MaxVal)
  9. SetSpellTriggerCount(100, 1)
  10. AddProc(Caster, 3, 8)
  11. end
  12. function proc(Caster, Target, Type, DmgType, MinVal, MaxVal)
  13. Spell = GetSpell(2550441)
  14. DmgBonus = math.floor(GetInt(Caster)/10)
  15. MinDmg = MinVal + DmgBonus
  16. MaxDmg = MaxVal + DmgBonus
  17. if Type == 3 then
  18. SetSpellDataIndex(Spell, 0, DmgType)
  19. SetSpellDataIndex(Spell, 1, MinDmg)
  20. SetSpellDataIndex(Spell, 2, MaxDmg)
  21. CastCustomSpell(Spell, Caster, Target)
  22. RemoveTriggerFromSpell(1)
  23. end
  24. end
  25. function remove(Caster, Target)
  26. RemoveProc(Caster)
  27. end