]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix showing the inventory button on entities without any inventory slots (#29728)
authorDrSmugleaf <10968691+DrSmugleaf@users.noreply.github.com>
Fri, 5 Jul 2024 14:25:23 +0000 (07:25 -0700)
committerGitHub <noreply@github.com>
Fri, 5 Jul 2024 14:25:23 +0000 (00:25 +1000)
Content.Client/UserInterface/Systems/Inventory/InventoryUIController.cs

index fb74779917080370bf61abbd8d7630703d00fd63..5d7a775104cb29ec178d428787a3fbf6d2ed7d4c 100644 (file)
@@ -132,6 +132,9 @@ public sealed class InventoryUIController : UIController, IOnStateEntered<Gamepl
         if (clientInv == null)
         {
             _inventoryHotbar?.ClearButtons();
+            if (_inventoryButton != null)
+                _inventoryButton.Visible = false;
+
             return;
         }
 
@@ -409,6 +412,8 @@ public sealed class InventoryUIController : UIController, IOnStateEntered<Gamepl
         {
             slotGroup.ClearButtons();
         }
+
+        UpdateInventoryHotbar(null);
     }
 
     private void SpriteUpdated(SlotSpriteUpdate update)