From 84aa1a7ce589d6047663916381ec09d7baa19144 Mon Sep 17 00:00:00 2001 From: tekki mariani Date: Tue, 24 Mar 2026 17:07:54 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix=20build=20tray=20background?= =?UTF-8?q?=20and=20buttons=20ignoring=20uiOpacity?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 4.6 --- src/scenes/UIScene.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/scenes/UIScene.ts b/src/scenes/UIScene.ts index 237c769..9d12b43 100644 --- a/src/scenes/UIScene.ts +++ b/src/scenes/UIScene.ts @@ -1259,7 +1259,7 @@ export class UIScene extends Phaser.Scene { const { width, height } = this.scale const trayY = height - UIScene.BAR_H - UIScene.TRAY_H - const bg = this.add.rectangle(0, trayY, width, UIScene.TRAY_H, 0x0d0d0d, 0.88) + const bg = this.add.rectangle(0, trayY, width, UIScene.TRAY_H, 0x0d0d0d, this.uiOpacity) .setOrigin(0, 0).setScrollFactor(0).setDepth(300) this.actionTrayGroup.add(bg) @@ -1275,10 +1275,10 @@ export class UIScene extends Phaser.Scene { const itemW = 84 buildings.forEach((b, i) => { const bx = 8 + i * (itemW + 4) - const btn = this.add.rectangle(bx, trayY + 4, itemW, UIScene.TRAY_H - 8, 0x1a2a1a, 0.9) + const btn = this.add.rectangle(bx, trayY + 4, itemW, UIScene.TRAY_H - 8, 0x1a2a1a, this.uiOpacity) .setOrigin(0, 0).setScrollFactor(0).setDepth(301).setInteractive() - btn.on('pointerover', () => btn.setFillStyle(0x2d4a2d, 0.9)) - btn.on('pointerout', () => btn.setFillStyle(0x1a2a1a, 0.9)) + btn.on('pointerover', () => btn.setFillStyle(0x2d4a2d, this.uiOpacity)) + btn.on('pointerout', () => btn.setFillStyle(0x1a2a1a, this.uiOpacity)) btn.on('pointerdown', () => { this.closeActionTray() this.deactivateCategory()