I have been working on this project for quite some time and everything was working fine, but one day I started the engine and ervy time I try to enter Landscape mode it crashes.
I also started getting this error yesterday after some intensive landscape editing. The error is specific to the project I am working on - other projects and new projects are fine.
@Bionic-Blob what is your video ram usage before switching to editing? Could it be possible that unreal doesnât have enough to allocate the texture once you switch to landscape mode?
@3dRaven Thanks for the suggestion. I checked if the file was there, it is. I also validated it and the folder. Its the same for me like @Bionic-Blob, All files Passed, and I have almost nothing in the scene, so I dont think its the VRAM, as i have other projects that have alot of assets that work just fine.
Are you running from a source build engine? If so you could track down the fail point in the engine.
The bool ULandscapeEditorObject::SetAlphaTexture in the cpp file seems to be setting the alpha texture for the terrain and not the editor brush.
There was a change between 5.0.3 source and 5.1
5.1 added a check
// Load fallback if there's no texture or valid data
if (NewAlphaTexture == nullptr)
{
UTexture2D* DefaultAlphaTexture = GetClass()->GetDefaultObject<ULandscapeEditorObject>()->AlphaTexture;
check((DefaultAlphaTexture != nullptr) && DefaultAlphaTexture->Source.IsValid()); // The default texture should always be valid
//..... more code
}
Iâm guessing GetClass()->GetDefaultObject()->AlphaTexture; is the line that sinks the engine. It for some reason returns a nullptr even though itâs supposed to be failproof.
If you added an alpha channel by hand then maybe it would not trigger the crash. (not sure how to do that out of engine though)
Thanks for looking at this 3dRaven. I took a process of elimination and started deleting & restoring folders inside the project to see if there was a cause.
Deleting \Saved\Config\WindowsEditor\EditorPerProjectUserSettings.ini resolve the issue, but I restored it too quick and UE overwrote it with a fresh version - I donât have the original broken version to share.
Unex could you see if this fixes your issue and potentially share the file please? I donât think there is anything sensitive in this config as far as I can tell - maybe if someone could confirm firstâŚ
Good suggestion @Darjlive deleting the entire LandscapeEdit section in EditorPerProjectUserSettings resolved the issue for me! I attempted your alpha solution, but also forgot to remove the entire line for testing purposes
edit: realized this error occured after i removed a file from the project containing an alpha brush used on the landscape
Hi everyone, sorry to bring this issue back but I was battling this for some 48h and I found yet another solution for it(for now) in case some else is still struggling.
Problem:
instant crash when Landscape Mode is activated
I have tried:
reinstalling UE 5.1 (worked until I decided to play with LandscapeMode again simply to create a Water Body Lake and eventually crash was back, zero landscape sculpting involved)
Deleting the [LandscapeEdit] section of the EditorPerProjectUserSettings.ini
Working solution for now:
Starting a fresh project worked, but I donât want to start fresh every timeâŚso I have overwritten the EditorPerProjectUserSettings.ini from the broken project, with the fresh one and it worked. A bit of a shotgun approach but I am new to this.
Sorry to bring this back again too but I just had this issue and based on all the information in this thread, changing the value of AlphaTextureName in the EditorPerProjectUserSettings.ini file to a new alpha texture worked for me.
To do this, add the alpha texture to your content folder, then in the ini, change the value to /Game/Name_of_alpha_texture.Name_of_alpha_texture
Simple solution: Go to Unreal Projects'âProjectFolderâ'\Saved\Config\WindowsEditor\EditorPerProjectUserSettings, Search [LandscapeEdit] See if you have a line like this ââAlphaTextureName=/xxxxxxxxââ and delete it then save.
Itâs caused by moving or deleting the brush texture on landscape mode. So donât forget to change the brush to something else before you delete or move the texture asset.