UE5 Editor crashes after deleting a Cesium3DTileset and saving

Hi,

every time I try to delete a Cesium3DTileset that I don’t need anymore in the UE5 Editor (UE 5.0.3, CESIUM plugin 1.17.0) the Editor crashes as soon as I want so save my work, here’s a screenshot of the asset that I tried to delete:

Afterwards the crash window pops up and gives me this error:

Fatal error: [File:D:\build++UE5\Sync\Engine\Source\Runtime\CoreUObject\Private\Templates\Casts.cpp] [Line: 10] Cast of Cesium3DTileset /Game/Maps/EDMO.EDMO:PersistentLevel.StuttgartFATO to MetaData failed

UnrealEditor_CoreUObject
UnrealEditor_Engine
UnrealEditor_CoreUObject
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_Engine
UnrealEditor_UnrealEd
UnrealEditor_UnrealEd
UnrealEditor_UnrealEd
UnrealEditor_UnrealEd
UnrealEditor_UnrealEd
UnrealEditor_UnrealEd
UnrealEditor_AssetTools
UnrealEditor_ContentBrowser
UnrealEditor_ContentBrowser
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_Slate
UnrealEditor_ApplicationCore
UnrealEditor_ApplicationCore
UnrealEditor_ApplicationCore
UnrealEditor_ApplicationCore
user32
user32
UnrealEditor_ApplicationCore
UnrealEditor
UnrealEditor
UnrealEditor
UnrealEditor
UnrealEditor
UnrealEditor
kernel32
ntdll

Any ideas?

Thanks & best
Andreasw

Hi @Lildreas, that’s a surprising error and the callstack doesn’t offer much help because you don’t seem to have any debug symbols (debug symbols are an optional component to install when installing Unreal Engine, but they take a lot of disk space). To narrow it down, are you able to reproduce this in the Cesium for Unreal Samples project as well, or does it only happen in your own project?

Hi @Kevin_Ring,

I was not able to reproduce this with the Cesium Unreal Sample project, so maybe something in my project went bad when converting from UE4 to UE5, or some edge case.

I added debug symbols to my UE5 installation, opened my project and deleted one of our Cesium3DTiles. Then I saved and got the crash:

Fatal error: [File:D:\build++UE5\Sync\Engine\Source\Runtime\CoreUObject\Private\Templates\Casts.cpp] [Line: 10] Cast of Cesium3DTileset /Game/Maps/EDMO.EDMO:PersistentLevel.StuttgartFATO to MetaData failed

UnrealEditor_CoreUObject!CastLogError() [D:\build++UE5\Sync\Engine\Source\Runtime\CoreUObject\Private\Templates\Casts.cpp:11]
UnrealEditor_Engine!<lambda_a17652fa219b0499deaca30883f88429>::operator()() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartitionActorDesc.cpp:375]
UnrealEditor_CoreUObject!ForEachObjectWithPackage() [D:\build++UE5\Sync\Engine\Source\Runtime\CoreUObject\Private\UObject\UObjectHash.cpp:1177]
UnrealEditor_Engine!FWorldPartitionActorDesc::Unload() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartitionActorDesc.cpp:381]
UnrealEditor_Engine!UWorldPartitionEditorCell::RemoveActor() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartitionEditorCell.cpp:95]
UnrealEditor_Engine!<lambda_ca0830827e878b73304e01db681ffd23>::operator()() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartitionEditorSpatialHash.cpp:232]
UnrealEditor_Engine!UWorldPartitionEditorSpatialHash::ForEachIntersectingCells() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Public\WorldPartition\WorldPartitionEditorSpatialHash.h:116]
UnrealEditor_Engine!UWorldPartitionEditorSpatialHash::UnhashActor() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartitionEditorSpatialHash.cpp:277]
UnrealEditor_Engine!UWorldPartition::UnhashActorDesc() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartition.cpp:1134]
UnrealEditor_Engine!UWorldPartition::OnActorDescRemoved() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\WorldPartition.cpp:1062]
UnrealEditor_Engine!UActorDescContainer::RemoveActor() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\ActorDescContainer.cpp:259]
UnrealEditor_Engine!UActorDescContainer::OnPackageDeleted() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\WorldPartition\ActorDescContainer.cpp:234]
UnrealEditor_Engine!TBaseUObjectMethodDelegateInstance<0,UActorDescContainer,void __cdecl(UPackage *),FDefaultDelegateUserPolicy>::ExecuteIfSafe() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Delegates\DelegateInstancesImpl.h:611]
UnrealEditor_UnrealEd!ObjectTools::CleanupAfterSuccessfulDelete() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\ObjectTools.cpp:2250]
UnrealEditor_UnrealEd!InternalPromptForCheckoutAndSave() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:3940]
UnrealEditor_UnrealEd!FEditorFileUtils::PromptForCheckoutAndSave() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:4246]
UnrealEditor_UnrealEd!FEditorFileUtils::PromptForCheckoutAndSave() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:4269]
UnrealEditor_UnrealEd!InternalSavePackages() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:3606]
UnrealEditor_UnrealEd!FEditorFileUtils::SaveDirtyPackages() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:3747]
UnrealEditor_AssetTools!AssetViewUtils::SaveDirtyPackages() [D:\build++UE5\Sync\Engine\Source\Developer\AssetTools\Private\AssetViewUtils.cpp:494]
UnrealEditor_ContentBrowser!SContentBrowser::OnSaveClicked() [D:\build++UE5\Sync\Engine\Source\Editor\ContentBrowser\Private\SContentBrowser.cpp:2544]
UnrealEditor_ContentBrowser!TBaseSPMethodDelegateInstance<0,SContentBrowser,1,FReply __cdecl(void),FDefaultDelegateUserPolicy>::Execute() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Delegates\DelegateInstancesImpl.h:290]
UnrealEditor_Slate!SButton::ExecuteOnClick() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Widgets\Input\SButton.cpp:464]
UnrealEditor_Slate!SButton::OnMouseButtonUp() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Widgets\Input\SButton.cpp:389]
UnrealEditor_Slate!<lambda_51e270ca99ea7ce852539efd04dd453f>::operator()() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:4959]
UnrealEditor_Slate!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,<lambda_51e270ca99ea7ce852539efd04dd453f> >() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:405]
UnrealEditor_Slate!FSlateApplication::RoutePointerUpEvent() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:4945]
UnrealEditor_Slate!FSlateApplication::ProcessMouseButtonUpEvent() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:5493]
UnrealEditor_Slate!FSlateApplication::OnMouseUp() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:5458]
UnrealEditor_ApplicationCore!FWindowsApplication::ProcessDeferredMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:2210]
UnrealEditor_ApplicationCore!FWindowsApplication::DeferMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:2699]
UnrealEditor_ApplicationCore!FWindowsApplication::ProcessMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:1078]
UnrealEditor_ApplicationCore!FWindowsApplication::AppWndProc() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:916]
user32
user32
UnrealEditor_ApplicationCore!FWindowsPlatformApplicationMisc::PumpMessages() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsPlatformApplicationMisc.cpp:138]
UnrealEditor!FEngineLoop::Tick() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\LaunchEngineLoop.cpp:5139]
UnrealEditor!GuardedMain() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Launch.cpp:183]
UnrealEditor!GuardedMainWrapper() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:147]
UnrealEditor!LaunchWindowsStartup() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:283]
UnrealEditor!WinMain() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:330]
UnrealEditor!__scrt_common_main_seh() [d:\a01_work\6\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288]
kernel32
ntdll

I additionally zipped the saved crash data folder for you, hope it helps to shed some light on this.
UECC-Windows-7E48A6E74C8073FC66C21DB3E6D1EBF9_0000.zip (174.7 KB)

And again - thanks for the awesome plugin and you continually handing out solutions to our problems!

Best,
Andreas

P.S.:
Regarding the other crash with building the HLODs, that has quite similar characteristics:
I removed everything CESIUM from my project and then tried to build the HLODs (the other crash I had), and it build the HLODs without a problem. Then I added the CESIUM World again, and the crash came back when building HLODs.

Hi @Lildreas,

I’m really not sure what’s going on there. It looks like Unreal code is trying to cast a Cesium3DTileset Actor to some other UObject type, which clearly isn’t going to work. Here’s the line of code at issue:
https://github.com/EpicGames/UnrealEngine/blob/5.0.3-release/Engine/Source/Runtime/Engine/Private/WorldPartition/WorldPartitionActorDesc.cpp#L375

What has caused it to do that, though, I really don’t know. Are you trying to use the world partition system to control a Cesium3DTileset? I think that will probably not go well (though I’m surprised to see it crash). World partition has some similarities (or at least overlapping use-cases) with Cesium’s tile streaming system, except that it’s 2D and extruded from a plane, which is not going to work for a globe. We understand some improvements are coming in UE5.1, so plan to take a closer look at it then. Until then, World Partition is not officially supported by Cesium for Unreal.

Kevin

1 Like

Hi @Kevin_Ring,

after your tip about WorldPartition I looked at this a bit closer:

I unchecked “Include Actor in HLOD” and “Is Spatially Loaded” (tells World Partition to load it based on distance to streaming sources) for all CESIUM actors, to have them in the persistent level all the time.

Then I checked the CESIUM actors and used the context menu to “Copy Actor File Path”. As you can see, the CESIUM actors are placed in the “ExternalActors” folder, following the World Partition “One File Per Actor” principle.

So I closed the UE Editor, removed the CESIUM actors from the ExternalActors files and loaded the project again. Of course now the CESIUM actors were gone, I created them anew.

Then I checked the paths again, and it gave me the following paths for the new CESIUM actors.
C:/Program Files/Epic Games/UE_5.0/Engine/Binaries/Win64/

I was happy. But only for a few moments, till I saved the project. Just saving it moved the CESIUM actors again into the “ExternalActors”.

I want to use World Partition to handle all my actors that are not converted to glTF and uploaded to the CESIUM servers, my Blueprint actors with logic.

Maybe this info will help you to come up with a solution - to somehow forbid the Editor to moved the CESIUM actors to the ExternalActors.

Best & have a nice weekend,
Andreas

1 Like

Hi @Lildreas,

I’m afraid I don’t know enough about the World Partition system to offer much assistance here. It could be worth raising the question on a more general Unreal Engine forum. As far as I know, Cesium for Unreal isn’t doing anything unusual with the Cesium3DTileset Actors here.

Kevin

I also meet the same problem. In a map with world parition, it happens. In a basic map, it’s gone.