From 8d42aa97b21f0c14cbbd3d55e615344b1fd09637 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B6=85=E7=BA=A7=E5=A6=96=E6=A2=A6=E5=8E=A8?= <12796194+youmuKon-supreme@user.noreply.gitee.com> Date: Wed, 5 Nov 2025 04:28:53 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B7=9F=E8=BF=9B=E6=9B=B4=E6=96=B0=EF=BC=9A?= =?UTF-8?q?=E6=A0=87=E8=AE=B0=E6=98=BE=E7=A4=BA=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- qml/lunarltk/Room.qml | 9 +++++++++ qml/lunarltk/components/Photo.qml | 8 +++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/qml/lunarltk/Room.qml b/qml/lunarltk/Room.qml index 8e035e4..a9462aa 100644 --- a/qml/lunarltk/Room.qml +++ b/qml/lunarltk/Room.qml @@ -1559,6 +1559,13 @@ W.PageBase { addToChat(pid, data); } + function updateMarkArea(sender, data) { + const { id, change } = data; + const photo = Logic.getPhoto(id); + if (!photo) return; + photo.handleMarkAreaUpdate(change); + } + Component.onCompleted: { addCallback(Command.NetStateChanged, netStateChanged); @@ -1623,6 +1630,8 @@ W.PageBase { addCallback(Command.GameLog, addToLog); addCallback(Command.Chat, chatToLog); + addCallback(Command.UpdateMarkArea, updateMarkArea); + playerNum = Config.roomCapacity; bgm.play(); diff --git a/qml/lunarltk/components/Photo.qml b/qml/lunarltk/components/Photo.qml index 2c34907..8fe018a 100644 --- a/qml/lunarltk/components/Photo.qml +++ b/qml/lunarltk/components/Photo.qml @@ -496,7 +496,6 @@ MyPhotoBase { OLMarkArea { id: markAreaItem - visible: !((root.dead && !root.rest) || root.dying || root.surrendered) x: 18 y: 18 @@ -798,6 +797,13 @@ MyPhotoBase { picMarkAreaItem.update(skill, time); } + function handleMarkAreaUpdate(data) { + if (data.visible !== undefined) { + // picMarkAreaItem.visible = data.visible; // 这是管限定技的区域? + markAreaItem.visible = data.visible; + } + } + function showDetail() { if (playerid === 0 || playerid === -1) { return; -- Gitee