function Name() return "attack" end function OnAdd(effectCtx) local power = effectCtx.source.getStat("atk").getValue() + effectCtx.potency local def = effectCtx.target.getStat("def").getValue() effectCtx.target.getStat("hp").subBase(power-def) effectCtx.remove() end