From 2997fa812f80e14959082b97a0887a273a3b4584 Mon Sep 17 00:00:00 2001 From: RisaDev <151885272+RisaDev@users.noreply.github.com> Date: Mon, 8 Apr 2024 00:42:11 +0300 Subject: [PATCH] Fix for penumbra redraw: do not search for actor using object table in GetArmaturesForCharacterName --- CustomizePlus/Armatures/Services/ArmatureManager.cs | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/CustomizePlus/Armatures/Services/ArmatureManager.cs b/CustomizePlus/Armatures/Services/ArmatureManager.cs index 3a45d2e..7f44526 100644 --- a/CustomizePlus/Armatures/Services/ArmatureManager.cs +++ b/CustomizePlus/Armatures/Services/ArmatureManager.cs @@ -553,16 +553,10 @@ public unsafe sealed class ArmatureManager : IDisposable private IEnumerable GetArmaturesForCharacterName(string characterName) { - var actors = _gameObjectService.FindActorsByName(characterName).ToList(); - if (actors.Count == 0) - yield break; - - foreach (var actorData in actors) + foreach(var kvPair in Armatures) { - if (!Armatures.TryGetValue(actorData.Item1, out var armature)) - continue; - - yield return armature; + if(kvPair.Key.ToNameWithoutOwnerName() == characterName) + yield return kvPair.Value; } } } \ No newline at end of file