* Fixed bug in condition.
@@ -38,18 +38,16 @@ import mage.watchers.common.PlayerDamagedBySourceWatcher;
*/
public class DealtDamageToAnOpponent implements Condition {
- public DealtDamageToAnOpponent() {
- }
-
@Override
public boolean apply(Game game, Ability source) {
for (UUID opponentId : game.getOpponents(source.getControllerId())) {
PlayerDamagedBySourceWatcher watcher = (PlayerDamagedBySourceWatcher) game.getState().getWatchers().get(PlayerDamagedBySourceWatcher.class.getSimpleName(), opponentId);
if (watcher != null) {
- return watcher.hasSourceDoneDamage(source.getSourceId(), game);
+ if (watcher.hasSourceDoneDamage(source.getSourceId(), game)) {
+ return true;
+ }
}
}
return false;
}
}
-
