v1.2.3: fixed up errors in freeze functionality changes in v1.2.0

This commit is contained in:
Evan Debenham
2022-04-12 16:33:30 -04:00
parent ad6fc6c071
commit 57727034ec

View File

@@ -72,8 +72,10 @@ public class Freezing extends Blob {
Buff.affect(ch, Frost.class, 2f);
} else {
Chill chill = ch.buff(Chill.class);
if (chill == null || chill.cooldown() <= Chill.DURATION - 3f) {
Buff.affect(ch, Chill.class, Dungeon.level.water[cell] ? 5f : 3f);
float turnsToAdd = Dungeon.level.water[cell] ? 5f : 3f;
if (chill != null) turnsToAdd = Math.min(turnsToAdd, Chill.DURATION - chill.cooldown());
if (turnsToAdd > 0f) {
Buff.affect(ch, Chill.class, turnsToAdd);
}
if (chill != null
&& chill.cooldown() >= Chill.DURATION &&