From e171186b177dfd749e48656a6048f8843015b73b Mon Sep 17 00:00:00 2001 From: duncathan Date: Tue, 23 Jun 2026 12:18:06 -0600 Subject: [PATCH] don't update cannon ball when clicking Refill fixes #6 --- src/UI/InventoryMenu.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/UI/InventoryMenu.cpp b/src/UI/InventoryMenu.cpp index 98bf49b..74ca3a7 100644 --- a/src/UI/InventoryMenu.cpp +++ b/src/UI/InventoryMenu.cpp @@ -219,6 +219,9 @@ namespace GUI { void refillItems(CPlayerState *playerState) { for (int i = 0; i < int(CPlayerState::EItemType::Max); i++) { auto itemType = static_cast(i); + if (itemType == CPlayerState::EItemType::CannonBall) { + continue; // otherwise the refill button always gives the player cannon ball + } u32 maxValue = CPlayerState::GetPowerUpMaxValue(itemType); playerState->ResetAndIncrPickUp(itemType, maxValue); }