fix: catch exceptions in events

This commit is contained in:
Anna 2021-04-16 08:21:29 -04:00
parent 33c7342fd8
commit 2e68e226ad
Signed by: anna
GPG Key ID: 0B391D8F06FCD9E0

View File

@ -3,6 +3,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Numerics;
using Dalamud.Game.Internal;
using Dalamud.Plugin;
using Lumina.Excel.GeneratedSheets;
namespace Tourist {
@ -81,9 +82,12 @@ namespace Tourist {
return;
}
this.RemoveAllVfx();
this.SpawnVfxForCurrentZone(territory);
try {
this.RemoveAllVfx();
this.SpawnVfxForCurrentZone(territory);
} catch (Exception ex) {
PluginLog.LogError(ex, "Exception in territory change");
}
}
private void OnFrameworkUpdate(Framework framework) {