When assigning an array of actors that implement a specific interface to an array of the specific interface the engine crashes. This doesn't happen if the actor array is put through a for each loop and checked for the interface before being added the interface array per element.
I have attached an example project.
Found in 4.22.3 CL#7053642
Reproduced in 4.23.0 CL#8386587, 4.24.0 Main CL#8707833
1. Create a new blueprint project.
2. Create a blueprint interface (BPI_Item)
3. Create a blueprint (BP_Item) that implements BPI_Item
4. Create a blueprint (BP_Consumer) that has an array of BPI_Items(ItemInterfaces).
5. Create a blueprint (BP_Inventory) that has an array of BP_Items (Items).
6. In BP_Inventory on BeginPlay spawn a BP_Item and store it in Items. Next spawn a BP_Consumer and set ItemInterfaces to Items.
7. Place a BP_Inventory in the level and play.
Results: The engine crashes.
Expected: The array is copied successfully.
LoginId:9a8d08644d702ac44f074090ac311686
EpicAccountId:580fb2844ad145d79dff08f42acea7c6
Unhandled exception
UE4Editor_CoreUObject!UClass::ImplementsInterface() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\class.cpp:3792]
UE4Editor_CoreUObject!UObject::execObjectToInterface() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:3096]
UE4Editor_CoreUObject!UObject::execLet() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:2100]
UE4Editor_CoreUObject!ProcessLocalScriptFunction() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:974]
UE4Editor_CoreUObject!ProcessScriptFunction<void (__cdecl*)(UObject *,FFrame &,void *)>() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:809]
UE4Editor_CoreUObject!ProcessLocalFunction() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:1033]
UE4Editor_CoreUObject!ProcessLocalScriptFunction() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:974]
UE4Editor_CoreUObject!UObject::ProcessInternal() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:1058]
UE4Editor_CoreUObject!UFunction::Invoke() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\class.cpp:4643]
UE4Editor_CoreUObject!UObject::ProcessEvent() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:1464]
UE4Editor_Engine!AActor::ProcessEvent() [d:\build\++ue4\sync\engine\source\runtime\engine\private\actor.cpp:769]
UE4Editor_DetailCustomizations!FObjectDetails::OnExecuteCallInEditorFunction() [d:\build\++ue4\sync\engine\source\editor\detailcustomizations\private\objectdetails.cpp:208]
UE4Editor_DetailCustomizations!TBaseSPMethodDelegateInstance<0,FObjectDetails,0,FReply __cdecl(void),TWeakObjectPtr<UFunction,FWeakObjectPtr> >::Execute() [d:\build\++ue4\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:279]
UE4Editor_Slate!SButton::OnMouseButtonUp() [d:\build\++ue4\sync\engine\source\runtime\slate\private\widgets\input\sbutton.cpp:293]
UE4Editor_Slate!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,<lambda_6c1f6b862bcfb82ea6dcab28fbcc9463> >() [d:\build\++ue4\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:271]
UE4Editor_Slate!FSlateApplication::RoutePointerUpEvent() [d:\build\++ue4\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5598]
UE4Editor_Slate!FSlateApplication::ProcessMouseButtonUpEvent() [d:\build\++ue4\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:6203]
UE4Editor_Slate!FSlateApplication::OnMouseUp() [d:\build\++ue4\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:6176]
UE4Editor_ApplicationCore!FWindowsApplication::ProcessDeferredMessage() [d:\build\++ue4\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:1842]
UE4Editor_ApplicationCore!FWindowsApplication::DeferMessage() [d:\build\++ue4\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:2292]
UE4Editor_ApplicationCore!FWindowsApplication::ProcessMessage() [d:\build\++ue4\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:1522]
UE4Editor_ApplicationCore!FWindowsApplication::AppWndProc() [d:\build\++ue4\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:772]
user32
user32
UE4Editor_ApplicationCore!FWindowsPlatformApplicationMisc::PumpMessages() [d:\build\++ue4\sync\engine\source\runtime\applicationcore\private\windows\windowsplatformapplicationmisc.cpp:130]
UE4Editor!FEngineLoop::Tick() [d:\build\++ue4\sync\engine\source\runtime\launch\private\launchengineloop.cpp:3882]
UE4Editor!GuardedMain() [d:\build\++ue4\sync\engine\source\runtime\launch\private\launch.cpp:168]
UE4Editor!GuardedMainWrapper() [d:\build\++ue4\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:145]
UE4Editor!WinMain() [d:\build\++ue4\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:275]
UE4Editor!__scrt_common_main_seh() [d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288]
kernel32
ntdll
How does TextureRenderTarget2D get TArray<uint8> type data?
How to delete some elements correctly when deleting an array loop?
What is the cause of the packaging error falling back to 'GameUserSettings' in ue5?
Why does the REMOVE method of map container remove elements have memory leaks?
UMG RichText not appear image when packaged
What is the difference between Camera and CineCamera?
How to assign a value to a member of UMG's UMaterialInterface pointer type in C++?
How to convert the datasmith scene file to BluePrint. Create animations in BluePrint.
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-80473 in the post.
1 |
Component | UE - Gameplay |
---|---|
Affects Versions | 4.23, 4.24, 4.22.3 |
Created | Sep 17, 2019 |
---|---|
Resolved | Aug 27, 2021 |
Updated | Aug 27, 2021 |