From ecfca5ff2df4a011fa86ea481bbcb3c68a5215fb Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Wed, 8 Dec 2021 19:56:14 -0500 Subject: [PATCH] v1.1.0: fixed cases where summoned elemental could be null --- .../shatteredpixeldungeon/items/spells/SummonElemental.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/spells/SummonElemental.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/spells/SummonElemental.java index 5cb55c549..ccacda806 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/spells/SummonElemental.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/spells/SummonElemental.java @@ -134,7 +134,7 @@ public class SummonElemental extends Spell { @Override public void restoreFromBundle(Bundle bundle) { super.restoreFromBundle(bundle); - summonClass = bundle.getClass(SUMMON_CLASS); + if (bundle.contains(SUMMON_CLASS)) summonClass = bundle.getClass(SUMMON_CLASS); } public WndBag.ItemSelector selector = new WndBag.ItemSelector() {