From 2dc9ff8aeb3d7fe196e2d50577a105b64c0fc06d Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Wed, 1 Mar 2023 13:12:00 -0500 Subject: [PATCH] v2.0.0: fixed unencumbered spirit items not dropping with full invent --- .../shatteredpixeldungeon/actors/hero/Talent.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/Talent.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/Talent.java index 02e3694e8..52cc97567 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/Talent.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/Talent.java @@ -390,8 +390,14 @@ public enum Talent { } if (talent == LIGHTLY_ARMED && hero.pointsInTalent(talent) == 3){ - new ClothArmor().identify().collect(); - new Gloves().identify().collect(); + Item toGive = new ClothArmor().identify(); + if (!toGive.collect()){ + Dungeon.level.drop(toGive, hero.pos).sprite.drop(); + } + toGive = new Gloves().identify(); + if (!toGive.collect()){ + Dungeon.level.drop(toGive, hero.pos).sprite.drop(); + } } }