mirror of
https://github.com/magefree/mage.git
synced 2025-12-28 06:22:01 -08:00
* Kruphix, God of Horizons - Fixed a bug that the mana pool was not correctly emptied (fixes #555).
This commit is contained in:
parent
72cd7a46ec
commit
2977cd27ea
3 changed files with 34 additions and 2 deletions
|
|
@ -7,7 +7,7 @@ package mage.constants;
|
|||
public enum ManaType {
|
||||
BLACK ("black"),
|
||||
BLUE ("blue"),
|
||||
GREEN ("greeen"),
|
||||
GREEN ("green"),
|
||||
RED ("red"),
|
||||
WHITE ("white"),
|
||||
COLORLESS("colorless");
|
||||
|
|
|
|||
|
|
@ -164,7 +164,9 @@ public class ManaPool implements Serializable {
|
|||
for (ManaType manaType: manaTypeArray) {
|
||||
if (item.get(manaType) > 0) {
|
||||
total += item.get(manaType);
|
||||
item.remove(manaType);
|
||||
while (item.get(manaType) > 0) {
|
||||
item.remove(manaType);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (item.count() == 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue