diff --git a/Mage.Sets/src/mage/cards/b/BalduvianWarlord.java b/Mage.Sets/src/mage/cards/b/BalduvianWarlord.java index 196e0544663..adfd89885b1 100644 --- a/Mage.Sets/src/mage/cards/b/BalduvianWarlord.java +++ b/Mage.Sets/src/mage/cards/b/BalduvianWarlord.java @@ -161,14 +161,18 @@ class BalduvianWarlordUnblockEffect extends OneShotEffect { // Relevant ruling for Balduvian Warlord: // 7/15/2006 If an attacking creature has an ability that triggers “When this creature becomes blocked,” // it triggers when a creature blocks it due to the Warlord’s ability only if it was unblocked at that point. - boolean notYetBlocked = chosenGroup.getBlockers().isEmpty(); chosenGroup.addBlocker(permanent.getId(), controller.getId(), game); + game.getCombat().addBlockingGroup(permanent.getId(), chosenPermanent.getId(), controller.getId(), game); // 702.21h if (notYetBlocked) { game.fireEvent(GameEvent.getEvent(GameEvent.EventType.CREATURE_BLOCKED, chosenPermanent.getId(), null)); } game.fireEvent(GameEvent.getEvent(GameEvent.EventType.BLOCKER_DECLARED, chosenPermanent.getId(), permanent.getId(), permanent.getControllerId())); } + CombatGroup blockGroup = findBlockingGroup(permanent, game); // a new blockingGroup is formed, so it's necessary to find it again + if (blockGroup != null) { + blockGroup.pickAttackerOrder(permanent.getControllerId(), game); + } } } return true; @@ -176,4 +180,15 @@ class BalduvianWarlordUnblockEffect extends OneShotEffect { } return false; } + + private CombatGroup findBlockingGroup(Permanent blocker, Game game) { + if (game.getCombat().blockingGroupsContains(blocker.getId())) { // if (blocker.getBlocking() > 1) { + for (CombatGroup group : game.getCombat().getBlockingGroups()) { + if (group.getBlockers().contains(blocker.getId())) { + return group; + } + } + } + return null; + } }