This commit is contained in:
2025-12-13 00:58:46 +01:00
parent f0308ddb3a
commit f6450cd3b8
17 changed files with 2401 additions and 32 deletions

View File

@@ -95,10 +95,12 @@ class InventorySystem {
updateUI() {
const uiScene = this.scene.scene.get('UIScene');
if (uiScene) {
uiScene.updateInventory(this.slots);
if (uiScene.updateGold) uiScene.updateGold(this.gold);
if (!uiScene || !uiScene.goldText) {
// UIScene not ready yet, skip update
return;
}
uiScene.updateInventory(this.slots);
if (uiScene.updateGold) uiScene.updateGold(this.gold);
}
hasItem(type, count) {