[DynamicBoneFix] Fix flexible gimmicks. #81

Merged
Njaecha merged 3 commits from GimmickFix into master 2025-09-10 16:00:15 +00:00
Njaecha commented 2025-09-10 15:35:35 +00:00 (Migrated from github.com)

Fixes the "bug" breaking some scenes mentioned in https://github.com/IllusionMods/IllusionFixes/issues/76 by fixing the premature end of the dynamic bone chain as explained in my comment.

Fixes the "bug" breaking some scenes mentioned in https://github.com/IllusionMods/IllusionFixes/issues/76 by fixing the premature end of the dynamic bone chain as explained in my comment.
ManlyMarco (Migrated from github.com) reviewed 2025-09-10 15:41:20 +00:00
@ -17,6 +21,23 @@ namespace IllusionFixes
ManlyMarco (Migrated from github.com) commented 2025-09-10 15:41:19 +00:00
                if (_info.group != 10 || _info.category != 2) return;
                var no = _info.no
                if (no != 393 && no != 395 && no != 492 && no != 492) return;
```suggestion if (_info.group != 10 || _info.category != 2) return; var no = _info.no if (no != 393 && no != 395 && no != 492 && no != 492) return; ```
ManlyMarco (Migrated from github.com) reviewed 2025-09-10 15:52:21 +00:00
@ -20,1 +38,4 @@
}
#endif
//Disable the SkipUpdateParticles method since it causes problems, namely causing jittering when the FPS is higher than 60
ManlyMarco (Migrated from github.com) commented 2025-09-10 15:52:21 +00:00
            // The game was abusing a bug in some gimmicks that got fixed by this plugin, so this changes the gimmicks to use the correct way to end the chain
            [HarmonyPostfix,  HarmonyPatch(typeof(Studio.AddObjectItem), nameof(Studio.AddObjectItem.Load), typeof(OIItemInfo), typeof(ObjectCtrlInfo), typeof(TreeNodeObject), typeof(bool), typeof(int))]
```suggestion // The game was abusing a bug in some gimmicks that got fixed by this plugin, so this changes the gimmicks to use the correct way to end the chain [HarmonyPostfix, HarmonyPatch(typeof(Studio.AddObjectItem), nameof(Studio.AddObjectItem.Load), typeof(OIItemInfo), typeof(ObjectCtrlInfo), typeof(TreeNodeObject), typeof(bool), typeof(int))] ```
Njaecha commented 2025-09-10 15:53:43 +00:00 (Migrated from github.com)

From Issue:
"The change to the fix I implemented had the core purpose of allowing multiple consecutive bones in the notRolls list since that would end the bonechain prematurely before. Ending the chain prematurely is done by adding the children of a bone to the Exclusions list. [...] However, the devs used the bug that makes a chain end by adding two consecutive bones to notRolls."

This PR intercepts the AddObjectItem.Load process and adds the "N_setuzoku" bone to the m_Exlcusions list and clears the m_notRolls list. Like that the dynamic bone chain correctly ends on the gimmick again and does not continue into the item parented to it.

From Issue: "The change to the fix I implemented had the core purpose of allowing multiple consecutive bones in the notRolls list since that would end the bonechain prematurely before. Ending the chain prematurely is done by adding the children of a bone to the Exclusions list. [...] However, the devs used the bug that makes a chain end by adding two consecutive bones to notRolls." This PR intercepts the AddObjectItem.Load process and adds the "N_setuzoku" bone to the m_Exlcusions list and clears the m_notRolls list. Like that the dynamic bone chain correctly ends on the gimmick again and does not continue into the item parented to it.
ManlyMarco (Migrated from github.com) approved these changes 2025-09-10 15:59:30 +00:00
Sign in to join this conversation.
No description provided.