I tried Blueprint nativization with 4.15’s Map container, then got an error.
Here’s my steps:
New blank project.
New BP “NewBlueprint”
New BP “MyActor2”
Add a map variable in NewBlueprint, Name as key, MyActor2 as value
Check both bps nativize
Blueprint nativization method exclusive
Package win64
And have this line:
Packaging (Windows (64-bit)): UnrealBuildTool: D:/Unreal4Works/blank1/Intermediate/WindowsNoEditor/NativizedAssets/Source/NativizedAssets/Public/NewBlueprint__pf1010915279.h(20) : Error: Unrecognized type 'AMyActor2_C' - type must be a UCLASS, USTRUCT or UENUM
In D:\Unreal4Works\blank1\Intermediate\WindowsNoEditor\NativizedAssets\Source\NativizedAssets\Public it has a file MyActor2__pf1010915279.h.
IF you take a look at the error that was provided in your original post you will see that it states “Error: Unrecognized type ‘AMyActor2_C’ - type must be a UCLASS, USTRUCT or UENUM” Meaning that the map that is being used has to have a class, struct, or enum reference. From the steps provided above, it sounds like you are using an actor reference here. Could you try changing this from a reference to the MyActor BP to the MyActor BP class and let me know if the package still fails?
Thanks for the reply.
I tried MyActor2 BP class, it worked.
But in real world case, I need to use reference as key or value.
I also tried to use built-in Actor reference as value, it worked as well.
I noticed that it generated the MyActor2__pf1010915279.h file, but it was looking for AMyActor2_C, that might be ‘AMyActor2__pf1010915279_C’ I guess?
And I tried to add another MyActor2 reference variable ‘myActor’ into NewBlueprint.
In generated file NewBlueprint__pf1010915279.h:
After doing a bit of digging I was able to find that this is a known issue. I have provided a link to the public tracker. Please feel free to use the link provided for future updates.
Is there already a target release set for this issue? This would be very helpful for the decision whether to use the new Set/Map containers (and just skip nativization until they are fixed) or not to use them if the fix will be some time later.