mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 10:40:06 -08:00
merge fix
This commit is contained in:
parent
62eb116124
commit
eec4f0ac7e
3 changed files with 11 additions and 16 deletions
|
|
@ -26,6 +26,7 @@ public abstract class CardWithSpellOption extends CardImpl {
|
|||
|
||||
public CardWithSpellOption(CardWithSpellOption card) {
|
||||
super(card);
|
||||
// make sure all parts created and parent ref added
|
||||
this.spellCard = card.getSpellCard().copy();
|
||||
this.spellCard.setParentCard(this);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,14 +62,11 @@ public abstract class ModalDoubleFacedCard extends CardImpl implements CardWithH
|
|||
|
||||
public ModalDoubleFacedCard(ModalDoubleFacedCard card) {
|
||||
super(card);
|
||||
if (card.leftHalfCard != null) {
|
||||
this.leftHalfCard = card.leftHalfCard.copy();
|
||||
((ModalDoubleFacedCardHalf) this.leftHalfCard).setParentCard(this);
|
||||
}
|
||||
if (card.rightHalfCard != null) {
|
||||
// make sure all parts created and parent ref added
|
||||
this.leftHalfCard = card.getLeftHalfCard().copy();
|
||||
((ModalDoubleFacedCardHalf) leftHalfCard).setParentCard(this);
|
||||
this.rightHalfCard = card.rightHalfCard.copy();
|
||||
((ModalDoubleFacedCardHalf) this.rightHalfCard).setParentCard(this);
|
||||
}
|
||||
((ModalDoubleFacedCardHalf) rightHalfCard).setParentCard(this);
|
||||
}
|
||||
|
||||
public ModalDoubleFacedCardHalf getLeftHalfCard() {
|
||||
|
|
|
|||
|
|
@ -38,14 +38,11 @@ public abstract class SplitCard extends CardImpl implements CardWithHalves {
|
|||
|
||||
protected SplitCard(SplitCard card) {
|
||||
super(card);
|
||||
if (card.leftHalfCard != null) {
|
||||
this.leftHalfCard = card.leftHalfCard.copy();
|
||||
((SplitCardHalf) this.leftHalfCard).setParentCard(this);
|
||||
}
|
||||
if (card.rightHalfCard != null) {
|
||||
// make sure all parts created and parent ref added
|
||||
this.leftHalfCard = card.getLeftHalfCard().copy();
|
||||
((SplitCardHalf) leftHalfCard).setParentCard(this);
|
||||
this.rightHalfCard = card.rightHalfCard.copy();
|
||||
((SplitCardHalf) this.rightHalfCard).setParentCard(this);
|
||||
}
|
||||
((SplitCardHalf) rightHalfCard).setParentCard(this);
|
||||
}
|
||||
|
||||
public void setParts(SplitCardHalf leftHalfCard, SplitCardHalf rightHalfCard) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue