Using put instead of map.replace.

This commit is contained in:
LevelX2 2014-08-18 09:31:42 +02:00
parent 1c71526616
commit 5ea1bc8c37

View file

@ -306,8 +306,7 @@ public class CombatGroup implements Serializable, Copyable<CombatGroup> {
defenderDamage(attacker, damage, game);
} else {
// Assign the damge left to first blocker
int alreadyAssigned = assigned.get(blockerOrder.get(0));
assigned.replace(blockerOrder.get(0), damage + alreadyAssigned);
assigned.put(blockerOrder.get(0), assigned.get(blockerOrder.get(0)) + damage);
}
}
for (UUID blockerId: blockerOrder) {