feat: Stop the movie from interrupting our beautiful beautiful changelog (#1894)

This commit is contained in:
KazWolfe 2024-07-04 09:28:56 -07:00 committed by GitHub
parent 4a3e6df89e
commit 8617c9c16d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -23,6 +23,8 @@ using Dalamud.Plugin.Services;
using Dalamud.Storage.Assets;
using Dalamud.Utility;
using FFXIVClientStructs.FFXIV.Client.UI;
using ImGuiNET;
namespace Dalamud.Interface.Internal.Windows;
@ -229,6 +231,9 @@ internal sealed class ChangelogWindow : Window, IDisposable
public override void PostDraw()
{
ImGui.PopStyleVar(3);
this.ResetMovieTimer();
base.PostDraw();
}
@ -571,6 +576,23 @@ internal sealed class ChangelogWindow : Window, IDisposable
this.openedThroughEligibility = true;
}
}
private unsafe void ResetMovieTimer()
{
var uiModule = UIModule.Instance();
if (uiModule == null)
return;
var agentModule = uiModule->GetAgentModule();
if (agentModule == null)
return;
var agentLobby = agentModule->GetAgentLobby();
if (agentLobby == null)
return;
agentLobby->IdleTime = 0;
}
private static class FtueLevels
{