Refactoring

See github line by line comments in 'File changed'
This commit is contained in:
vraskulin 2016-12-29 16:49:12 +03:00
parent c0cf22bbf7
commit f04ba151f7
52 changed files with 87 additions and 220 deletions

View file

@ -90,10 +90,7 @@ public class TargetCreatureOrPlayer extends TargetImpl {
return filter.match(permanent, game);
}
Player player = game.getPlayer(id);
if (player != null) {
return filter.match(player, game);
}
return false;
return player != null && filter.match(player, game);
}
@Override
@ -119,10 +116,7 @@ public class TargetCreatureOrPlayer extends TargetImpl {
if (permanent != null) {
return filter.match(permanent, game);
}
if (player != null) {
return filter.match(player, game);
}
return false;
return player != null && filter.match(player, game);
}
/**