From 5749fedd351f068055afc8ed46b35aeb2d438987 Mon Sep 17 00:00:00 2001 From: AlexCube Date: Tue, 13 Oct 2026 17:18:43 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=BE=D1=8F=D1=81=20=D0=BF=D0=B5=D1=80?= =?UTF-8?q?=D1=81=D0=BE=D0=BD=D0=B0=D0=B6=D0=B0=20=D0=BE=D1=82=20=D0=BF?= =?UTF-8?q?=D0=B5=D1=80=D0=B2=D0=BE=D0=B3=D0=BE=20=D0=BB=D0=B8=D1=86=D0=B0?= =?UTF-8?q?=20=D1=81=D0=BA=D1=80=D1=8B=D0=B2=D0=B0=D0=B5=D1=82=D1=81=D1=8F?= =?UTF-8?q?=20=D0=BF=D1=80=D0=BE=D0=B7=D1=80=D0=B0=D1=87=D0=BD=D0=BE=D1=81?= =?UTF-8?q?=D1=82=D1=8C=D1=8E=20=D0=BE=D0=BA=D0=BD=D0=B0=20(IsVisible=20?= =?UTF-8?q?=D0=BD=D0=B5=20=D0=B4=D0=B5=D1=80=D0=B6=D0=B0=D0=BB=D1=81=D1=8F?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- HarmonySrc/Possession.cs | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/HarmonySrc/Possession.cs b/HarmonySrc/Possession.cs index b959e53..302846c 100644 --- a/HarmonySrc/Possession.cs +++ b/HarmonySrc/Possession.cs @@ -2179,12 +2179,26 @@ namespace NecromancerTome static void ShowPlayerBelt(bool _show) { XUiV_Window w = _player?.PlayerUI?.xui?.GetWindow("windowToolbelt"); - if (w != null && w.IsVisible != _show) + if (w == null) { - w.IsVisible = _show; + if (!_show && !_beltMissingLogged) + { + _beltMissingLogged = true; + Debug.LogWarning("[NecromancerTome] Possession: окно windowToolbelt не найдено - пояс персонажа не скрыть"); + } + return; + } + // Прозрачность окна, а не IsVisible (тест 13.10: с IsVisible пояс оставался виден - окно показывают снова). + // ForceVisible(0) держит его прозрачным до следующего открытия окна. + float a = _show ? 1f : 0f; + if (w.PanelAlpha != a) + { + w.ForceVisible(a); } } + static bool _beltMissingLogged; + /// Тело одержимого в виде от первого лица - только тень (тест 13.10: изнутри видно тело, у паука на /// бегу лапы и череп в кадре; сжатие одной головы не спасало). Видимость - дело своего экрана: другие игроки /// рисуют этого зомби сами и видят его как обычно; так же игра прячет тело персонажа от первого лица.