Change overlay draw conditions

mnk-heavensward
Liza 2024-07-30 04:47:06 +02:00
parent 1c0c75a2a6
commit 3de284d96b
Signed by: liza
GPG Key ID: 7199F8D727D55F67
1 changed files with 7 additions and 6 deletions

View File

@ -48,12 +48,7 @@ internal sealed class DebugOverlay : Window
public ushort? HighlightedQuest { get; set; } public ushort? HighlightedQuest { get; set; }
public override bool DrawConditions() public override bool DrawConditions() => _configuration.Advanced.DebugOverlay;
{
return _configuration.Advanced.DebugOverlay && _clientState is
{ IsLoggedIn: true, LocalPlayer: not null, IsPvPExcludingDen: false } &&
!_condition[ConditionFlag.OccupiedInCutSceneEvent];
}
public override void PreDraw() public override void PreDraw()
{ {
@ -62,6 +57,12 @@ internal sealed class DebugOverlay : Window
public override void Draw() public override void Draw()
{ {
if (_condition[ConditionFlag.OccupiedInCutSceneEvent])
return;
if (_clientState is not { IsLoggedIn: true, LocalPlayer: not null, IsPvPExcludingDen: false })
return;
DrawCurrentQuest(); DrawCurrentQuest();
DrawHighlightedQuest(); DrawHighlightedQuest();
} }