From 87c7e0909bce3beea17be3c9a14ee990360e3982 Mon Sep 17 00:00:00 2001 From: unanmed <1319491857@qq.com> Date: Wed, 26 Feb 2025 21:34:38 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9E=81=E6=98=BC=E6=B0=B8=E5=A4=9C?= =?UTF-8?q?=E6=95=B0=E5=80=BC=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/module/render/ui/main.tsx | 6 ++++-- src/module/render/ui/statusBar.tsx | 11 +++++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/module/render/ui/main.tsx b/src/module/render/ui/main.tsx index 4fc8368..0758634 100644 --- a/src/module/render/ui/main.tsx +++ b/src/module/render/ui/main.tsx @@ -107,7 +107,8 @@ const MainScene = defineComponent(() => { springCount: 0, floor: 'MT0', replaying: false, - replayStatus + replayStatus, + night: 0 }); const { getHeroStatusOn } = Mota.requireAll('fn'); @@ -133,10 +134,11 @@ const MainScene = defineComponent(() => { leftStatus.exAtk = getHeroStatusOn('mana'); leftStatus.magicDef = getHeroStatusOn('magicDef'); - const { HeroSkill } = Mota.require('module', 'Mechanism'); + const { HeroSkill, NightSpecial } = Mota.require('module', 'Mechanism'); rightStatus.autoSkill = HeroSkill.getAutoSkill(); rightStatus.skillName = HeroSkill.getSkillName(); rightStatus.skillDesc = HeroSkill.getSkillDesc(); + rightStatus.night = NightSpecial.getNight(floor); rightStatus.floor = floor; rightStatus.replaying = core.isReplaying(); const { pausing, speed, toReplay, totalList } = core.status.replay; diff --git a/src/module/render/ui/statusBar.tsx b/src/module/render/ui/statusBar.tsx index 631abc2..d90c20a 100644 --- a/src/module/render/ui/statusBar.tsx +++ b/src/module/render/ui/statusBar.tsx @@ -195,6 +195,8 @@ export interface IRightHeroStatus { replaying: boolean; /** 录像播放状态 */ replayStatus: ReplayingStatus; + /** 极昼永夜 */ + night: number; } export const RightStatusBar = defineComponent>( @@ -246,6 +248,15 @@ export const RightStatusBar = defineComponent>( valueColor: '#a7ffa7' }); } + if (s.night !== 0) { + const text = s.night.toString(); + data.push({ + name: '极昼永夜', + nameColor: '#a3f8ff', + value: s.night > 0 ? '+' + text : text, + valueColor: s.night > 0 ? '#a7ffa7' : '#ffa7a7' + }); + } return data; });