FActorSpawnParameters not exposed to blueprints

Hi,

I’m working on a project-code actor spawning system, whose blueprint nodes eventually pipe through to the standard SpawnActor() call. I’ve noticed that FActorSpawnParameters is not a BlueprintType, which means I have to manually combine individual parameters of a blueprint node into a struct instance.

Is there a reason it’s not already a BlueprintType? If not - Do you see any reason for us to not make it as a local change?

Thanks,

Zoe

Hey Zoe, after asking this internally we wouldn’t want to turn FActorSpawnParameters into a BlueprintType now because it has many members that we don’t want to expose to blueprint or cannot be exposed to blueprint like:

TFunction<void(AActor*)> CustomPreSpawnInitalization;“If not - Do you see any reason for us to not make it as a local change?”

Yes, some of the members can’t be turned into UPROPERTIES, so will not be automatically serialized. That includes the TFunction, but also properties that are only present in editor builds.

If you need more blueprint exposed spawn control I recommend looking into subclassing UK2Node_SpawnActorFromClass to create your own spawning node that remains adaptive to ExposeOnSpawn parameters but has extra configurable properties that are converted to FActorSpawnParameters values in its native implementation.