(final SpellAbility source, final boolean effect)
| 6947 | } |
| 6948 | |
| 6949 | public final boolean canBeSacrificedBy(final SpellAbility source, final boolean effect) { |
| 6950 | if (isImmutable()) { |
| 6951 | System.out.println("Trying to sacrifice immutables: " + this); |
| 6952 | return false; |
| 6953 | } |
| 6954 | |
| 6955 | if (!isInPlay() || isPhasedOut()) { |
| 6956 | return false; |
| 6957 | } |
| 6958 | |
| 6959 | // can't sacrifice it for mana ability if it is already marked as sacrifice |
| 6960 | if (source != null && source.isManaAbility() && isUsedToPay()) { |
| 6961 | return false; |
| 6962 | } |
| 6963 | |
| 6964 | final Card gameCard = game.getCardState(this, null); |
| 6965 | // gameCard is LKI in that case, the card is not in game anymore |
| 6966 | // or the timestamp did change |
| 6967 | // this should check Self too |
| 6968 | if (gameCard == null || !this.equalsWithGameTimestamp(gameCard)) { |
| 6969 | return false; |
| 6970 | } |
| 6971 | |
| 6972 | return !StaticAbilityCantSacrifice.cantSacrifice(this, source, effect); |
| 6973 | } |
| 6974 | |
| 6975 | public final boolean canExiledBy(final SpellAbility source, final boolean effect) { |
| 6976 | return !StaticAbilityCantExile.cantExile(this, source, effect); |
no test coverage detected