From 20cc798f8498c4e51c16f67cd993ce326cb4a55d Mon Sep 17 00:00:00 2001 From: Anna Date: Thu, 8 Apr 2021 12:52:07 -0400 Subject: [PATCH] feat: use error toast for error --- Peeping Tom/PluginUi.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Peeping Tom/PluginUi.cs b/Peeping Tom/PluginUi.cs index 0e20f25..c982b5a 100644 --- a/Peeping Tom/PluginUi.cs +++ b/Peeping Tom/PluginUi.cs @@ -545,14 +545,11 @@ namespace PeepingTom { if (actor != null) { this.Plugin.GameFunctions.OpenExamineWindow(actor); } else { - Payload[] payloads = { - new TextPayload($"[{this.Plugin.Name}] "), + var error = new SeString(new Payload[] { new PlayerPayload(this.Plugin.Interface.Data, targeter.Name, targeter.HomeWorld.Id), new TextPayload(" is not close enough to examine."), - }; - this.Plugin.Interface.Framework.Gui.Chat.PrintChat(new XivChatEntry { - MessageBytes = new SeString(payloads).Encode(), }); + this.Plugin.Interface.Framework.Gui.Toast.ShowError(error); } } else { var payload = new PlayerPayload(this.Plugin.Interface.Data, targeter.Name, targeter.HomeWorld.Id);