mirror of
https://github.com/magefree/mage.git
synced 2025-12-24 12:31:59 -08:00
[CMR] Implemented Yurlock of Scorch Thrash
This commit is contained in:
parent
5578437dde
commit
e387cf3c54
4 changed files with 153 additions and 1 deletions
|
|
@ -1540,7 +1540,10 @@ public abstract class GameImpl implements Game, Serializable {
|
|||
@Override
|
||||
public void emptyManaPools() {
|
||||
for (Player player : getPlayers().values()) {
|
||||
player.getManaPool().emptyPool(this);
|
||||
int amount = player.getManaPool().emptyPool(this);
|
||||
if (state.isManaBurn() && amount > 0) {
|
||||
player.loseLife(amount, this, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -103,6 +103,7 @@ public class GameState implements Serializable, Copyable<GameState> {
|
|||
private int permanentOrderNumber;
|
||||
private final Map<UUID, FilterCreaturePermanent> usePowerInsteadOfToughnessForDamageLethalityFilters = new HashMap<>();
|
||||
private Set<MageObjectReference> commandersToStay = new HashSet<>(); // commanders that do not go back to command zone
|
||||
private boolean manaBurn = false;
|
||||
|
||||
private int applyEffectsCounter; // Upcounting number of each applyEffects execution
|
||||
|
||||
|
|
@ -1089,6 +1090,7 @@ public class GameState implements Serializable, Copyable<GameState> {
|
|||
state.clearAbilities();
|
||||
}
|
||||
cardAttribute.clear();
|
||||
this.setManaBurn(false);
|
||||
}
|
||||
|
||||
public void clear() {
|
||||
|
|
@ -1269,4 +1271,12 @@ public class GameState implements Serializable, Copyable<GameState> {
|
|||
void setCommanderShouldStay(Card card, Game game) {
|
||||
commandersToStay.add(new MageObjectReference(card, game));
|
||||
}
|
||||
|
||||
public void setManaBurn(boolean manaBurn) {
|
||||
this.manaBurn = manaBurn;
|
||||
}
|
||||
|
||||
public boolean isManaBurn() {
|
||||
return manaBurn;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue