Accessories with more "unique" DBDE bone names and Timeline #175

Open
opened 2025-11-30 06:27:32 +00:00 by AX_MMD · 0 comments

So I found this bug when removing a hair accessory that has a non-standard bone name and a DBDE interpolable in Timeline.
I'm posting here since the error occurs in DBDE first, but involves HSPE.AMModules.DynamicBonesEditor+TimelineCompatibility down the line.

First error happens in DBDE when removing/swapping the acc (there is no visible issue when it happens):

The trace when you remove the item (no apparent symptoms)
[Debug  :DynamicBoneDistributionEditor] Applying Data for outfit 5 on character Haruno Chika (from Delayed)
KeyNotFoundException: The given key was not present in the dictionary.

List<DBDEDynamicBoneEdit> System.Collections.Generic.Dictionary<int, System.Collections.Generic.List<DynamicBoneDistributionEditor.DBDEDynamicBoneEdit>>.get_Item(int)
bool DynamicBoneDistributionEditor.DBDECharaController+<ApplyCurrentDelayed>d__23.MoveNext()
void UnityEngine.SetupCoroutine.InvokeMoveNext(IEnumerator, IntPtr)

Then, if I need to do something that will interact with a DBDE interpolable linked to that bone (like collapsing a section), the Timeline will crash and become unusable:

The trace when you interact with timeline
NullReferenceException: Object reference not set to an instance of an object

void HSPE.AMModules.DynamicBonesEditor+TimelineCompatibility.Populate()+(string, ObjectCtrlInfo, object)➞string [9]
string Timeline.Interpolable.get_name()
void Timeline.Timeline.UpdateInterpolablesViewTree(List<INode>, bool, int, int, float, int)
void Timeline.Timeline.UpdateInterpolablesView()
HeaderDisplay Timeline.Timeline.GetHeaderDisplay(int, bool)+(PointerEventData)➞void [0]
void UILib.EventHandlers.PointerDownHandler.OnPointerDown(PointerEventData)
bool UnityEngine.EventSystems.ExecuteEvents.Execute<IPointerDownHandler>(GameObject, BaseEventData, EventFunction<IPointerDownHandler>)
UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object)
UnityEngine.DebugLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
UnityEngine.EventSystems.ExecuteEvents:Execute(GameObject, BaseEventData, EventFunction`1)
UnityEngine.EventSystems.ExecuteEvents:ExecuteHierarchy(GameObject, BaseEventData, EventFunction`1)
UnityEngine.EventSystems.StandaloneInputModule:ProcessMousePress(MouseButtonEventData)
UnityEngine.EventSystems.StandaloneInputModule:ProcessMouseEvent(Int32)
UnityEngine.EventSystems.StandaloneInputModule:ProcessMouseEvent()
UnityEngine.EventSystems.StandaloneInputModule:Process()
UnityEngine.EventSystems.EventSystem:Update()

(On the right, keyframes are all jumbled up after collapsing a section)

The key error happens in DBDE, but the crash happens when DynamicBonesEditor+TimelineCompatibility receives a null.
Perhaps the Timeline integration could remove the interpolable when it gets a null.

NC had a similar issue before v1.6 with NC interpolables, causing a Timeline crash when the target item of an NC interpolable was removed.

Minimal example:
minimal_example.zip

So I found this bug when removing a hair accessory that has a non-standard bone name and a DBDE interpolable in Timeline. I'm posting here since the error occurs in DBDE first, but involves `HSPE.AMModules.DynamicBonesEditor+TimelineCompatibility` down the line. First error happens in DBDE when removing/swapping the acc (there is no visible issue when it happens): <details> <summary>The trace when you remove the item (no apparent symptoms)</summary> [Debug :DynamicBoneDistributionEditor] Applying Data for outfit 5 on character Haruno Chika (from Delayed) KeyNotFoundException: The given key was not present in the dictionary. List<DBDEDynamicBoneEdit> System.Collections.Generic.Dictionary<int, System.Collections.Generic.List<DynamicBoneDistributionEditor.DBDEDynamicBoneEdit>>.get_Item(int) bool DynamicBoneDistributionEditor.DBDECharaController+<ApplyCurrentDelayed>d__23.MoveNext() void UnityEngine.SetupCoroutine.InvokeMoveNext(IEnumerator, IntPtr) </details> Then, if I need to do something that will interact with a DBDE interpolable linked to that bone (like collapsing a section), the Timeline will crash and become unusable: <details> <summary>The trace when you interact with timeline</summary> NullReferenceException: Object reference not set to an instance of an object void HSPE.AMModules.DynamicBonesEditor+TimelineCompatibility.Populate()+(string, ObjectCtrlInfo, object)➞string [9] string Timeline.Interpolable.get_name() void Timeline.Timeline.UpdateInterpolablesViewTree(List<INode>, bool, int, int, float, int) void Timeline.Timeline.UpdateInterpolablesView() HeaderDisplay Timeline.Timeline.GetHeaderDisplay(int, bool)+(PointerEventData)➞void [0] void UILib.EventHandlers.PointerDownHandler.OnPointerDown(PointerEventData) bool UnityEngine.EventSystems.ExecuteEvents.Execute<IPointerDownHandler>(GameObject, BaseEventData, EventFunction<IPointerDownHandler>) UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object) UnityEngine.DebugLogHandler:LogException(Exception, Object) UnityEngine.Logger:LogException(Exception, Object) UnityEngine.Debug:LogException(Exception) UnityEngine.EventSystems.ExecuteEvents:Execute(GameObject, BaseEventData, EventFunction`1) UnityEngine.EventSystems.ExecuteEvents:ExecuteHierarchy(GameObject, BaseEventData, EventFunction`1) UnityEngine.EventSystems.StandaloneInputModule:ProcessMousePress(MouseButtonEventData) UnityEngine.EventSystems.StandaloneInputModule:ProcessMouseEvent(Int32) UnityEngine.EventSystems.StandaloneInputModule:ProcessMouseEvent() UnityEngine.EventSystems.StandaloneInputModule:Process() UnityEngine.EventSystems.EventSystem:Update() </details> (On the right, keyframes are all jumbled up after collapsing a section) | <img src="https://github.com/user-attachments/assets/277d4132-8f04-4c9e-b5bf-55fab3cfe594" width="400" /> | <img src="https://github.com/user-attachments/assets/376e2ac1-995e-44fa-8796-0a62fdd830fe" width="400" /> | |:---:|:---:| The key error happens in DBDE, but the crash happens when `DynamicBonesEditor+TimelineCompatibility` receives a null. Perhaps the Timeline integration could remove the interpolable when it gets a null. NC had a similar issue before v1.6 with NC interpolables, causing a Timeline crash when the target item of an NC interpolable was removed. Minimal example: [minimal_example.zip](https://github.com/user-attachments/files/23837956/minimal_example.zip)
Commenting is not possible because the repository is archived.
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
IllusionMods/HSPlugins#175
No description provided.