From 3d2cec77c04466a50f23199477a12ef145814c44 Mon Sep 17 00:00:00 2001 From: goat Date: Sat, 20 Apr 2024 17:08:40 +0200 Subject: [PATCH] Revert "ioc: actually make early blocking services blocking again" This reverts commit 1d75c8edda36d03fff27e33a11c6dfb10494bb3d. To be reapplied in #1779. --- Dalamud/Dalamud.cs | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/Dalamud/Dalamud.cs b/Dalamud/Dalamud.cs index 8cc47ed33..f9d2aff3c 100644 --- a/Dalamud/Dalamud.cs +++ b/Dalamud/Dalamud.cs @@ -68,16 +68,10 @@ internal sealed class Dalamud : IServiceType // Set up FFXIVClientStructs this.SetupClientStructsResolver(cacheDir); - - void KickoffGameThread() - { - Log.Verbose("=============== GAME THREAD KICKOFF ==============="); - Timings.Event("Game thread kickoff"); - NativeFunctions.SetEvent(mainThreadContinueEvent); - } if (!configuration.IsResumeGameAfterPluginLoad) { + NativeFunctions.SetEvent(mainThreadContinueEvent); ServiceManager.InitializeEarlyLoadableServices() .ContinueWith(t => { @@ -89,8 +83,6 @@ internal sealed class Dalamud : IServiceType "Dalamud failed to load all necessary services.\n\nThe game will continue, but you may not be able to use plugins.", "Dalamud", false); }); - - ServiceManager.BlockingResolved.ContinueWith(_ => KickoffGameThread()); } else { @@ -109,7 +101,7 @@ internal sealed class Dalamud : IServiceType if (faultedTasks.Any()) throw new AggregateException(faultedTasks); - KickoffGameThread(); + NativeFunctions.SetEvent(mainThreadContinueEvent); await Task.WhenAll(tasks); } @@ -120,7 +112,7 @@ internal sealed class Dalamud : IServiceType } finally { - KickoffGameThread(); + NativeFunctions.SetEvent(mainThreadContinueEvent); } }); }