AdmonishingInvocation.lua 712 B

123456789101112131415161718192021222324252627282930
  1. --[[
  2. Script Name : dd_interrupt.lua
  3. Script Purpose : Generic damage + stun script
  4. Script Author : John Adams
  5. Script Date : 2008.12.04
  6. --]]
  7. function cast(Caster, Target, DDType, MinDDVal, MaxDDVal, EffectType, EffectChance)
  8. -- DD component
  9. if MaxDDVal ~= nil and MinDDVal < MaxDDVal then
  10. SpellDamage(Target, DDType, math.random(MinDDVal, MaxDDVal))
  11. else
  12. SpellDamage(Target, DDType, MinDDVal)
  13. end
  14. -- Effect component - if EffectChance is blank, always apply the effect, otherwise random
  15. if EffectChance ~= nil then
  16. if EffectChance >= math.random(1, 100) then
  17. -- Interrupt(Target)
  18. end
  19. else
  20. -- Interrupt(Target)
  21. end
  22. end
  23. function remove(Caster, Target)
  24. end