mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
- A better and more correct fix for X propagation.
This commit is contained in:
@@ -234,14 +234,13 @@ public class HumanPlaySpellAbility {
|
||||
}
|
||||
|
||||
ability.setSVar("X", value.toString());
|
||||
card.setSVar("X", value.toString());
|
||||
|
||||
// announce to subabilities
|
||||
SpellAbility sub = ability.getSubAbility();
|
||||
do {
|
||||
SpellAbility sub = ability;
|
||||
while ((sub = sub.getSubAbility()) != null) {
|
||||
sub.setSVar("X", value.toString());
|
||||
} while ((sub = sub.getSubAbility()) != null);
|
||||
|
||||
card.setSVar("X", value.toString());
|
||||
};
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user