From 61fbeeb46bd8498d3bcd97c33a5692f348d066a9 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Mon, 1 Feb 2021 14:05:27 -0500 Subject: [PATCH] v0.9.2: removed duplicated code in Dungeon.init() --- .../com/shatteredpixel/shatteredpixeldungeon/Dungeon.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java index 15b716e11..eab3ca631 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java @@ -200,8 +200,7 @@ public class Dungeon { droppedItems = new SparseArray<>(); portedItems = new SparseArray<>(); - for (LimitedDrops a : LimitedDrops.values()) - a.count = 0; + LimitedDrops.reset(); chapters = new HashSet<>(); @@ -382,7 +381,7 @@ public class Dungeon { } Light light = hero.buff( Light.class ); - hero.viewDistance = light == null ? level.viewDistance : Math.max( Light.DISTANCE, level.viewDistance ); + hero.viewDistance = 2; hero.curAction = hero.lastAction = null;