Files
UnrealEngineUWP/Engine/Source/Editor/LandscapeEditor
jonathan bard 0270cbb1ae Fixed crash when dropping a BP actor with a nested water body actor in a map with a landscape but no water brush and/or water mesh actor: in that case, the addition of the actor will trigger a UWorld::SpawnActor to create the missing actors, which is forbidden during a construction script :
* Changed the API of the actor factory's CreateActor/SpawnActor in order to take a FActorSpawnParameters in parameter, so as to expose UWorld::SpawnActor's own option to the factory user.
* The level pointer is still part of the function prototypes in order to make it explicit to the user that he needs to pass in a valid ULevel (rather than relying on FActorSpawnParameters's OverrideLevel, which is easy to miss). In the case where OverrideLevel is indeed passed within FActorSpawnParameters, the functions validate that the pointer is the same as the level param
* Also, removed automatic creation of water mesh actor on map load : this is not playing well with world partition because it will keep on creating new actors if the level containing the water mesh actor is not loaded

#rb marc.audy, kevin.ortegren
#jira none
#tests editor + full build preflight

[CL 16219600 by jonathan bard in ue5-main branch]
2021-05-06 08:19:17 -04:00
..