hello,
I’m having a crash every time I close a PIE session or closing my character BP window. this never happened in 4.9 and I haven’t touched my code in months (probably since 4.7). just recently I converted it from 4.9 to 4.10 and now that I actually tried to play I get this crash.
so whenever I do PIE and close it, or open my character blueprint and close it, the engine will crash into this:
Assertion failed: ChildCount >
AttachChildren.Num()
[File:D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.10\Engine\Source\Runtime\Engine\Private\Components\SceneComponent.cpp]
[Line: 676] AttachChildren count
increased while detaching ‘None’,
likely caused by OnAttachmentChanged
introducing new children, which could
lead to an infinite loop.
this is the callstack for the PIE crash:
UE4Editor-Engine.dll!USceneComponent::OnComponentDestroyed() Line 676 C++
UE4Editor-Engine.dll!UActorComponent::BeginDestroy() Line 388 C++
UE4Editor-Engine.dll!UPrimitiveComponent::BeginDestroy() Line 855 C++
UE4Editor-CoreUObject.dll!UObject::ConditionalBeginDestroy() Line 659 C++
UE4Editor-CoreUObject.dll!CollectGarbageInternal(EObjectFlags KeepFlags, bool bPerformFullPurge) Line 1362 C++
UE4Editor-CoreUObject.dll!CollectGarbage(EObjectFlags KeepFlags, bool bPerformFullPurge) Line 1400 C++
UE4Editor-UnrealEd.dll!UEditorEngine::EndPlayMap() Line 328 C++
UE4Editor-UnrealEd.dll!UEditorEngine::Tick(float DeltaSeconds, bool bIdleMode) Line 978 C++
and this is the callstack for closing my character BP:
UE4Editor-Engine.dll!USceneComponent::OnComponentDestroyed() Line 676 C++
UE4Editor-Engine.dll!AActor::MarkComponentsAsPendingKill() Line 3722 C++
UE4Editor-Engine.dll!UWorld::DestroyActor(AActor * ThisActor, bool bNetForce, bool bShouldModifyLevel) Line 640 C++
UE4Editor-Engine.dll!UWorld::EditorDestroyActor(AActor * ThisActor, bool bShouldModifyLevel) Line 471 C++
UE4Editor-Kismet.dll!FBlueprintEditor::DestroyPreview() Line 7863 C++
in both cases it crashes into USceneComponent::OnComponentDestroyed(), on this line:
checkf(ChildCount > AttachChildren.Num(), TEXT("AttachChildren count increased while detaching '%s', likely caused by OnAttachmentChanged introducing new children, which could lead to an infinite loop."), *Child->GetName());
I checked with the debugger and ChildCount is 1, and AttachChildren.Num() is also 1. and the scenecomponent definately looks like it’s owned by my Character.
maybe it’s worth pointing out that I use several other custom-made C++ Components that I attach to my Character.
any ideas of something new that could introduce this?