mirror of
https://github.com/correl/mage.git
synced 2024-11-15 11:09:30 +00:00
Merge pull request #6249 from Dilnu/Mogis
Fix Mogis God of Slaughter's ability when a player has no creatures.
This commit is contained in:
commit
8ab21be00c
1 changed files with 4 additions and 1 deletions
|
@ -77,9 +77,12 @@ class MogisGodOfSlaughterEffect extends OneShotEffect {
|
|||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(game.getActivePlayerId());
|
||||
if (player == null || game.getBattlefield().countAll(StaticFilters.FILTER_PERMANENT_CREATURE, game.getActivePlayerId(), game) == 0) {
|
||||
if (player == null) {
|
||||
return false;
|
||||
}
|
||||
if (game.getBattlefield().countAll(StaticFilters.FILTER_PERMANENT_CREATURE, game.getActivePlayerId(), game) == 0) {
|
||||
return player.damage(2, source.getSourceId(), game) > 0;
|
||||
}
|
||||
TargetPermanent target = new TargetControlledCreaturePermanent(1);
|
||||
target.setNotTarget(true);
|
||||
if (target.canChoose(player.getId(), game)
|
||||
|
|
Loading…
Reference in a new issue