Skip to content

Commit

Permalink
item stats: Fix equipment item container check NPE
Browse files Browse the repository at this point in the history
  • Loading branch information
Nightfirecat committed Dec 11, 2024
1 parent 1e05bdf commit 00e6d98
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
import lombok.Getter;
import lombok.Setter;
import net.runelite.api.InventoryID;
import net.runelite.api.ItemContainer;
import net.runelite.api.ItemID;
import net.runelite.api.Skill;
import net.runelite.api.Varbits;
Expand Down Expand Up @@ -75,7 +76,8 @@ public StatChange effect(Client client)
multiplier += 0.2;
}

if (client.getItemContainer(InventoryID.EQUIPMENT).contains(ItemID.SUNLIT_BRACERS))
final ItemContainer equipment = client.getItemContainer(InventoryID.EQUIPMENT);
if (equipment != null && equipment.contains(ItemID.SUNLIT_BRACERS))
{
multiplier += 1;
}
Expand Down

0 comments on commit 00e6d98

Please sign in to comment.