BlueprintImplementableEvent and Shipping Build (Windows) UE 5.5

C++ parent:
UFUNCTION(BlueprintImplementableEvent, Category = “Soul”)
void GoToNewLocation(FVector NewLocation);

Blueprint implementation exists to blueprint child.
Editor build and development build - Ok.
Shipping build - from Cpp Called GoToNewLocation method and crash applcation.

CallStack:
000000ce7617d900 00007ff85c102554 ntdll!RtlpExecuteHandlerForException+0xf
06 000000ce7617d930 00007ff85c1513ce ntdll!RtlDispatchException+0x244
07 000000ce7617e040 00007ff6f0ef5ba8 ntdll!KiUserExceptionDispatch+0x2e
08 000000ce7617e770 00007ff6f3f7c148 Hell_Win64_Shipping!UObject::FindFunctionChecked+0x18
09 000000ce7617e7d0 00007ff6f3f8de83 Hell_Win64_Shipping!AHLLSoul::GoToNewLocation+0x28

from generated gen.cpp:

static const FName NAME_AHLLSoul_GoToNewLocation = FName(TEXT(“GoToNewLocation”));
void AHLLSoul::GoToNewLocation(FVector NewLocation)
{
HLLSoul_eventGoToNewLocation_Parms Parms;
Parms.NewLocation=NewLocation;
UFunction* Func = FindFunctionChecked(NAME_AHLLSoul_GoToNewLocation); //crash point
ProcessEvent(Func,&Parms);
}

How to fix this behavior? Why can’t it find the implemented blueprint function (event) with this name in the Shipping build, even though it works fine in the editor and the Development build?

Blueprint Implementation:

What about dependencies on uncooked modules? I had a crash when calling such “questionable” functions in the build, while everything worked in the editor.

What about dependencies on uncooked modules? I had a crash when calling such “questionable” functions in the build, while everything worked in the editor.

What you means? Can you tell us more?

This code is in the project module. And it added to the target rule. (ExtraModuleNames).
This is the first time I’ve encountered such a situation. :slight_smile:

.uproject or some .uplugin file has something like:


You could include some file in your runtime module, which is located in such an uncooked module.

You could add such a module to the .build.cs file so that the include would work and the VS solution would build successfully, but in a packed project - it would cause a crash when trying to call a function from an uncooked module.

my .uproject and .uplugin (custom plugins) uses Type: Runtime. LoadingPhase: Default

I identified the issue. I was storing the AActor collection in TDeque<AActor*>, but this container type doesn’t support UPROPERTY. As a result, the garbage collector eventually marks AActor instances for garbage collection and begins purging their data. This appears to be exactly what happened.

I replaced TDeque with TArray<AActor*> and add UPROPERTY specifier. Shipping build is work correctly.

1 Like