Make settings change invoke on Temporary Mods.

This commit is contained in:
Ottermandias 2024-02-18 13:03:56 +01:00
parent 80ce6fe21f
commit 31bc5ec6f9
3 changed files with 7 additions and 1 deletions

View file

@ -1,3 +1,4 @@
using Penumbra.Api.Enums;
using Penumbra.Collections;
using Penumbra.Meta.Manipulations;
using Penumbra.Mods;
@ -84,11 +85,13 @@ public class TempModManager : IDisposable
{
Penumbra.Log.Verbose($"Removing temporary Mod {mod.Name} from {collection.AnonymizedName}.");
collection.Remove(mod);
_communicator.ModSettingChanged.Invoke(collection, ModSettingChange.TemporaryMod, null, 0, 0, false);
}
else
{
Penumbra.Log.Verbose($"Adding {(created ? "new " : string.Empty)}temporary Mod {mod.Name} to {collection.AnonymizedName}.");
collection.Apply(mod, created);
_communicator.ModSettingChanged.Invoke(collection, ModSettingChange.TemporaryMod, null, 1, 0, false);
}
}
else