J :
* Fix interface (when a creature has trample and exactly one blocker, show the damage assignation screen)
This commit is contained in:
@@ -472,15 +472,17 @@ int GuiCombat::receiveEventMinus(WEvent* e)
|
|||||||
return 1;
|
return 1;
|
||||||
case DAMAGE: DAMAGE:
|
case DAMAGE: DAMAGE:
|
||||||
step = event->step;
|
step = event->step;
|
||||||
if (!go->currentPlayer->displayStack()) {
|
if (!go->currentPlayer->displayStack()) {
|
||||||
((AIPlayer *)go->currentPlayer)->affectCombatDamages(step);
|
((AIPlayer *)go->currentPlayer)->affectCombatDamages(step);
|
||||||
go->nextGamePhase();
|
go->nextGamePhase();
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
for (inner_iterator attacker = attackers.begin(); attacker != attackers.end(); ++attacker)
|
for (inner_iterator attacker = attackers.begin(); attacker != attackers.end(); ++attacker)
|
||||||
autoaffectDamage(*attacker, step);
|
autoaffectDamage(*attacker, step);
|
||||||
for (inner_iterator it = attackers.begin(); it != attackers.end(); ++it)
|
for (inner_iterator it = attackers.begin(); it != attackers.end(); ++it)
|
||||||
(*it)->show = ((*it)->card->has(Constants::DOUBLESTRIKE) || ((*it)->card->has(Constants::FIRSTSTRIKE) ^ (DAMAGE == step))) && (1 < (*it)->blockers.size());
|
(*it)->show = ((*it)->card->has(Constants::DOUBLESTRIKE) || ((*it)->card->has(Constants::FIRSTSTRIKE) ^ (DAMAGE == step))) &&
|
||||||
|
(((*it)->card->has(Constants::TRAMPLE) ? 0 : 1) < (*it)->blockers.size()
|
||||||
|
);
|
||||||
repos<AttackerDamaged>(attackers.begin(), attackers.end(), 0);
|
repos<AttackerDamaged>(attackers.begin(), attackers.end(), 0);
|
||||||
active = NULL;
|
active = NULL;
|
||||||
for (inner_iterator it = attackers.begin(); it != attackers.end(); ++it) if ((*it)->show) { active = *it; break; }
|
for (inner_iterator it = attackers.begin(); it != attackers.end(); ++it) if ((*it)->show) { active = *it; break; }
|
||||||
|
|||||||
Reference in New Issue
Block a user