diff --git a/client/Messages.cs b/client/Messages.cs index d9381e9..a954ac6 100644 --- a/client/Messages.cs +++ b/client/Messages.cs @@ -18,7 +18,9 @@ internal class Messages : IDisposable { internal Messages(Plugin plugin) { this.Plugin = plugin; - this.SpawnVfx(); + if (this.Plugin.Config.ApiKey != string.Empty) { + this.SpawnVfx(); + } this.Plugin.Framework.Update += this.HandleSpawnQueue; this.Plugin.ClientState.Login += this.SpawnVfx; diff --git a/client/OrangeGuidanceTomestone.csproj b/client/OrangeGuidanceTomestone.csproj index c7223d0..d93bcd6 100755 --- a/client/OrangeGuidanceTomestone.csproj +++ b/client/OrangeGuidanceTomestone.csproj @@ -1,7 +1,7 @@ - 1.0.0 + 1.0.1 net6.0-windows enable enable diff --git a/client/Plugin.cs b/client/Plugin.cs index edb5127..c846e8c 100644 --- a/client/Plugin.cs +++ b/client/Plugin.cs @@ -33,19 +33,20 @@ public class Plugin : IDalamudPlugin { public Plugin() { this.Config = this.Interface!.GetPluginConfig() as Configuration ?? new Configuration(); + this.Vfx = new Vfx(); + this.Messages = new Messages(this); + this.Ui = new PluginUi(this); + this.Commands = new Commands(this); + if (this.Config.ApiKey == string.Empty) { Task.Run(async () => { var resp = await new HttpClient().PostAsync("https://tryfingerbuthole.anna.lgbt/account", null); var key = await resp.Content.ReadAsStringAsync(); this.Config.ApiKey = key; this.SaveConfig(); + this.Messages.SpawnVfx(); }); } - - this.Vfx = new Vfx(); - this.Messages = new Messages(this); - this.Ui = new PluginUi(this); - this.Commands = new Commands(this); } public void Dispose() {