2018-02-15 13:20:46 -06:00
|
|
|
require("global");
|
|
|
|
require("magic");
|
|
|
|
|
|
|
|
function onMagicPrepare(caster, target, spell)
|
|
|
|
return 0;
|
|
|
|
end;
|
|
|
|
|
|
|
|
function onMagicStart(caster, target, spell)
|
|
|
|
return 0;
|
|
|
|
end;
|
|
|
|
|
|
|
|
--Increased damage and conversion to single target
|
|
|
|
function onCombo(caster, target, spell)
|
|
|
|
spell.aoeType = 0;
|
|
|
|
spell.potency = spell.potency * 1.5;
|
|
|
|
end;
|
|
|
|
|
2018-04-18 16:06:41 -05:00
|
|
|
function onSkillFinish(caster, target, skill, action, actionContainer)
|
2018-02-15 13:20:46 -06:00
|
|
|
--Dispels an effect on each target.
|
2018-04-18 16:06:41 -05:00
|
|
|
local effects = target.statusEffects.GetStatusEffectsByFlag2(16); --lose on dispel
|
2018-02-15 13:20:46 -06:00
|
|
|
if effects != nil then
|
|
|
|
target.statusEffects.RemoveStatusEffect(effects[0]);
|
|
|
|
end;
|
2018-04-18 16:06:41 -05:00
|
|
|
|
|
|
|
--calculate damage
|
|
|
|
action.amount = skill.basePotency;
|
|
|
|
|
|
|
|
--DoAction handles rates, buffs, dealing damage
|
|
|
|
action.DoAction(caster, target, skill, actionContainer);
|
|
|
|
|
|
|
|
--Try to apply status effect
|
|
|
|
action.TryStatus(caster, target, skill, actionContainer, true);
|
2018-02-15 13:20:46 -06:00
|
|
|
end;
|