forked from External/mage
Continuing implementation of Planechase.
This commit is contained in:
parent
c8b741f0bf
commit
87d19c7d51
8 changed files with 242 additions and 12 deletions
|
|
@ -1034,7 +1034,7 @@ public abstract class GameImpl implements Game, Serializable {
|
|||
watchers.add(new BlockedAttackerWatcher());
|
||||
watchers.add(new DamageDoneWatcher());
|
||||
watchers.add(new PlanarRollWatcher());
|
||||
|
||||
|
||||
//20100716 - 103.5
|
||||
for (UUID playerId : state.getPlayerList(startingPlayerId)) {
|
||||
Player player = getPlayer(playerId);
|
||||
|
|
@ -1072,10 +1072,12 @@ public abstract class GameImpl implements Game, Serializable {
|
|||
cardsWithOpeningAction.remove(card);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 20180408 - 901.5
|
||||
if (gameOptions.planeChase) {
|
||||
addPlane(Plane.getRandomPlane(), null, getActivePlayerId());
|
||||
Plane plane = Plane.getRandomPlane();
|
||||
plane.setControllerId(getActivePlayerId());
|
||||
addPlane(plane, null, getActivePlayerId());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1544,7 +1546,7 @@ public abstract class GameImpl implements Game, Serializable {
|
|||
public boolean addPlane(Plane plane, MageObject sourceObject, UUID toPlayerId) {
|
||||
// Implementing planechase as if it were 901.15. Single Planar Deck Option
|
||||
// Here, can enforce the world plane restriction (the Grand Melee format may have some impact on this implementation)
|
||||
|
||||
|
||||
// Enforce 'world' rule for planes
|
||||
for (CommandObject cobject : state.getCommand()) {
|
||||
if (cobject instanceof Plane) {
|
||||
|
|
@ -1560,6 +1562,7 @@ public abstract class GameImpl implements Game, Serializable {
|
|||
ability.setSourceId(newPlane.getId());
|
||||
}
|
||||
state.addCommandObject(newPlane);
|
||||
informPlayers("You have planeswalked to " + newPlane.getLogName());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue