DamageDealEffect: add RelativeTarget for to be relative to Damage Source

This commit is contained in:
Hanmac
2017-10-16 17:54:57 +00:00
parent 6cff21f47b
commit 0fb0837561

View File

@@ -163,7 +163,11 @@ public class DamageDealEffect extends DamageBaseEffect {
}
return;
}
if (sa.hasParam("RelativeTarget")) {
tgts = AbilityUtils.getDefinedObjects(source, sa.getParam("Defined"), sa);
}
for (final Object o : tgts) {
dmg = (sa.usesTargeting() && sa.hasParam("DividedAsYouChoose")) ? sa.getTargetRestrictions().getDividedValue(o) : dmg;
if (o instanceof Card) {