mirror of
https://github.com/correl/mage.git
synced 2025-01-12 11:08:01 +00:00
* Fixed possible null pointer exceptions.
This commit is contained in:
parent
cd6917be93
commit
946b723361
2 changed files with 2 additions and 2 deletions
|
@ -76,7 +76,7 @@ public class CantAttackYouAllEffect extends RestrictionEffect {
|
|||
@Override
|
||||
public boolean canAttack(Permanent attacker, UUID defenderId, Ability source, Game game) {
|
||||
return (!alsoPlaneswalker && !defenderId.equals(source.getControllerId()))
|
||||
|| (alsoPlaneswalker && !game.getCombat().getDefendingPlayerId(attacker.getId(), game).equals(source.getControllerId()));
|
||||
|| (alsoPlaneswalker && !(source.getControllerId().equals(game.getCombat().getDefendingPlayerId(attacker.getId(), game))));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -79,7 +79,7 @@ public class ManifestEffect extends OneShotEffect {
|
|||
for (Card card : cards) {
|
||||
ManaCosts manaCosts = null;
|
||||
if (card.getCardType().contains(CardType.CREATURE)) {
|
||||
manaCosts = card.getSpellAbility().getManaCosts();
|
||||
manaCosts = card.getSpellAbility() != null ? card.getSpellAbility().getManaCosts() : null;
|
||||
if (manaCosts == null) {
|
||||
manaCosts = new ManaCostsImpl("{0}");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue