mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 18:58:00 +00:00
TargetRestictions don't need to be copied, they may be just reused
This commit is contained in:
@@ -317,8 +317,7 @@ public class CardFactoryUtil {
|
||||
|
||||
@Override
|
||||
public AbilityActivated getCopy() {
|
||||
AbilityActivated res = new AbilityTransmute(getSourceCard(),
|
||||
getPayCosts(), getTargetRestrictions() == null ? null : new TargetRestrictions(getTargetRestrictions()));
|
||||
AbilityActivated res = new AbilityTransmute(getSourceCard(), getPayCosts(), getTargetRestrictions());
|
||||
CardFactory.copySpellAbility(this, res);
|
||||
res.getRestrictions().setZone(ZoneType.Hand);
|
||||
return res;
|
||||
@@ -353,7 +352,7 @@ public class CardFactoryUtil {
|
||||
}
|
||||
}
|
||||
|
||||
if (sameCost.size() == 0) {
|
||||
if (sameCost.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user