Change overlay draw conditions

This commit is contained in:
Liza 2024-07-30 04:47:06 +02:00
parent 1c0c75a2a6
commit 3de284d96b
Signed by: liza
GPG Key ID: 7199F8D727D55F67

View File

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