mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
- added other zones to Painter's Servant #8168
This commit is contained in:
parent
261f32d9b9
commit
5b4e167ff4
1 changed files with 56 additions and 0 deletions
|
@ -88,6 +88,20 @@ class PaintersServantEffect extends ContinuousEffectImpl {
|
||||||
}
|
}
|
||||||
// Exile
|
// Exile
|
||||||
for (Card card : game.getExile().getAllCards(game)) {
|
for (Card card : game.getExile().getAllCards(game)) {
|
||||||
|
// handle MDFC
|
||||||
|
if (card instanceof ModalDoubleFacesCard) {
|
||||||
|
ModalDoubleFacesCardHalf leftHalfCard = ((ModalDoubleFacesCard) card).getLeftHalfCard();
|
||||||
|
ModalDoubleFacesCardHalf rightHalfCard = ((ModalDoubleFacesCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
|
// handle Split-Cards
|
||||||
|
if (card instanceof SplitCard) {
|
||||||
|
SplitCardHalf leftHalfCard = ((SplitCard) card).getLeftHalfCard();
|
||||||
|
SplitCardHalf rightHalfCard = ((SplitCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
||||||
}
|
}
|
||||||
// Command
|
// Command
|
||||||
|
@ -95,6 +109,20 @@ class PaintersServantEffect extends ContinuousEffectImpl {
|
||||||
if (commandObject instanceof Commander) {
|
if (commandObject instanceof Commander) {
|
||||||
Card card = game.getCard(((Commander) commandObject).getId());
|
Card card = game.getCard(((Commander) commandObject).getId());
|
||||||
if (card != null) {
|
if (card != null) {
|
||||||
|
// handle MDFC
|
||||||
|
if (card instanceof ModalDoubleFacesCard) {
|
||||||
|
ModalDoubleFacesCardHalf leftHalfCard = ((ModalDoubleFacesCard) card).getLeftHalfCard();
|
||||||
|
ModalDoubleFacesCardHalf rightHalfCard = ((ModalDoubleFacesCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
|
// handle Split-Cards
|
||||||
|
if (card instanceof SplitCard) {
|
||||||
|
SplitCardHalf leftHalfCard = ((SplitCard) card).getLeftHalfCard();
|
||||||
|
SplitCardHalf rightHalfCard = ((SplitCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -126,10 +154,38 @@ class PaintersServantEffect extends ContinuousEffectImpl {
|
||||||
}
|
}
|
||||||
// Library
|
// Library
|
||||||
for (Card card : player.getLibrary().getCards(game)) {
|
for (Card card : player.getLibrary().getCards(game)) {
|
||||||
|
// handle MDFC
|
||||||
|
if (card instanceof ModalDoubleFacesCard) {
|
||||||
|
ModalDoubleFacesCardHalf leftHalfCard = ((ModalDoubleFacesCard) card).getLeftHalfCard();
|
||||||
|
ModalDoubleFacesCardHalf rightHalfCard = ((ModalDoubleFacesCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
|
// handle Split-Cards
|
||||||
|
if (card instanceof SplitCard) {
|
||||||
|
SplitCardHalf leftHalfCard = ((SplitCard) card).getLeftHalfCard();
|
||||||
|
SplitCardHalf rightHalfCard = ((SplitCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
||||||
}
|
}
|
||||||
// Graveyard
|
// Graveyard
|
||||||
for (Card card : player.getGraveyard().getCards(game)) {
|
for (Card card : player.getGraveyard().getCards(game)) {
|
||||||
|
// handle MDFC
|
||||||
|
if (card instanceof ModalDoubleFacesCard) {
|
||||||
|
ModalDoubleFacesCardHalf leftHalfCard = ((ModalDoubleFacesCard) card).getLeftHalfCard();
|
||||||
|
ModalDoubleFacesCardHalf rightHalfCard = ((ModalDoubleFacesCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
|
// handle Split-Cards
|
||||||
|
if (card instanceof SplitCard) {
|
||||||
|
SplitCardHalf leftHalfCard = ((SplitCard) card).getLeftHalfCard();
|
||||||
|
SplitCardHalf rightHalfCard = ((SplitCard) card).getRightHalfCard();
|
||||||
|
game.getState().getCreateMageObjectAttribute(leftHalfCard, game).getColor().addColor(color);
|
||||||
|
game.getState().getCreateMageObjectAttribute(rightHalfCard, game).getColor().addColor(color);
|
||||||
|
}
|
||||||
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
game.getState().getCreateMageObjectAttribute(card, game).getColor().addColor(color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue