From 773e3be1177dee93e502d9e31cc35e2af13d45e1 Mon Sep 17 00:00:00 2001 From: troytt <47798984@qq.com> Date: Fri, 2 Oct 2026 10:53:45 +0000 Subject: [PATCH] chore: resolve merge types in world-panels, hud-manager and client-world --- src/client/ui/hud-manager.ts | 4 ++-- src/client/ui/world-panels.ts | 7 ++++--- src/client/world/client-world.ts | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/client/ui/hud-manager.ts b/src/client/ui/hud-manager.ts index 7904295..7622d2f 100644 --- a/src/client/ui/hud-manager.ts +++ b/src/client/ui/hud-manager.ts @@ -563,8 +563,8 @@ export class HudManager { /** Server-authoritative death / mercenary / party / trade state synced by `HudModel`. */ isDead = false merc: any = null - hireList: any[] = [] - mercHireList: any[] = [] + hireList: readonly any[] = [] + mercHireList: readonly any[] = [] partyMembers: any[] = [] summonPortraits: any[] = [] trade: any = null diff --git a/src/client/ui/world-panels.ts b/src/client/ui/world-panels.ts index 94ddaab..f4161f8 100644 --- a/src/client/ui/world-panels.ts +++ b/src/client/ui/world-panels.ts @@ -49,6 +49,7 @@ import { type VendorNpcId, getTownNpcDescriptorByName, getTownNpcDescriptorByVendorId, + getTownNpcDescriptorByHcIdx, getLocalizedNpcName, getLocalizedNpcGreetings, } from '../../common/units/npc-table.ts' @@ -863,8 +864,8 @@ export class WorldPanelsHud { private _activePanel: WorldPanelType = 'none' isDead = false merc: any = null - hireList: any[] = [] - mercHireList: any[] = [] + hireList: readonly any[] = [] + mercHireList: readonly any[] = [] hireScrollOffset = 0 hireSelectedIndex = -1 hireHoveredIndex: number | null = null @@ -3686,7 +3687,7 @@ export class WorldPanelsHud { // Warning text: "This Mercenary will replace your current one." (VerifyTransaction9) const warnText = lookupTbl('VerifyTransaction9', this.lang) ?? (this.lang === 'ENG' ? 'This Mercenary will replace your current one.' : '這個傭兵會換掉前一位。') if (font) { - this.drawWrappedText(ctx, font, warnText, cx + 24, cy + 32, confirmW - 48, 16, 4, 'font16', 'gold', 'center') + this.drawWrappedText(ctx, font, warnText, cx + 24, cy + 32, confirmW - 48, 16, 4, 'fontformal12') } else { fillTextSafe(warnText, cx + 24, cy + 32, '#e8c26b') } diff --git a/src/client/world/client-world.ts b/src/client/world/client-world.ts index 1d9f947..c0cb20a 100644 --- a/src/client/world/client-world.ts +++ b/src/client/world/client-world.ts @@ -932,7 +932,7 @@ export class ClientWorld { this._containers.clearShop() this._npcInteraction = { ...cur, npcId: cmd.npcId, window: 'gamble', activeWindow: 'gamble' } } else if (cmd.action === 3) { - this._npcInteraction = { ...cur, npcId: cmd.npcId, window: 'hire', activeWindow: 'hire' } + this._npcInteraction = { ...cur, npcId: cmd.npcId, window: 'none', activeWindow: 'hire' } } break case 'NpcCancel':