From 9c44d1d7cba5bdadfb8696454da9bd81ea40a913 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Tue, 12 Jul 2016 23:05:24 -0400 Subject: [PATCH] v0.4.1: fixed crashes on floor 26 --- src/com/shatteredpixel/shatteredpixeldungeon/ui/StatusPane.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/ui/StatusPane.java b/src/com/shatteredpixel/shatteredpixeldungeon/ui/StatusPane.java index 21f3379cb..8181d9c32 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/ui/StatusPane.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/ui/StatusPane.java @@ -265,7 +265,7 @@ public class StatusPane extends Component { boolean blackKey = false; boolean specialKey = false; int ironKeys = 0; - for (int i = 1; i <= Dungeon.depth; i++) { + for (int i = 1; i <= Math.min(Dungeon.depth, 25); i++) { if (Dungeon.hero.belongings.ironKeys[i] > 0 || Dungeon.hero.belongings.specialKeys[i] > 0) { foundKeys = true;