Line trace on Landscape stucks in specific places

Hi. I have problem with landscape.
In my project I want to build complex AI, and one of experiment is to analyze level’s height map (level will be generated in future). So, I create grid of landscape points and try to check visibility between them. Trace works fast, but in several places (I found at least 3) it stucks.
Here is example - I removed all from my level: logic actors, navigation, even foliage and material.


I draw debug line in level’s BeginPlay:

When I press Key 1 (perform line trace) - UE stucks forever. But if I try reverse direction - it works fine:

Trace also works even if I just change on point’s Z coordinate (tried 1225.521):

I use US 5.4.2 and don’t have any experience with UE source code debugging, all what I know - line trace is started and is not ended. Any ideas?

Here are my Landscape settings. Is it acceptable resolution?
5

Try putting the drag debug line after the line trace


Like that? It still stucks.

do you mean the editor no response or the debug line apears forever?
if it’s debug line you can decrease the line duration.

@baobao4435 “stucks” - application (PIE or Standalone) freezes forever. On this trace instruction (in C++ or blueprints). I see 100% activity on one core of CPU. But from logs - trace cannot finish execution.

1 Like

this sounds like an infinite loop.
i guess it’s a bug or something.maybe you could report a bug to epic.

I tried to decrease landscape’s resolution. Lost my foliage, but don’t see problem. It is my first expirience with UE Landscape, probably I set very high resolution. Will continue investigation.

Looks like problem is in Landscape actor. I exported it into FBX as static mesh (its size is 90M+, LOD0, so it has really high resolution), imported back into unreal in replaced landscape by this mesh. I lost material and foliage, but logic works, problem is not reproduced. Will try to decrease resolution of existing landscape.

I found solution. I exported landscape as static mesh, imported it back, placed to level and aligned to original landscape, disable collision for landscape, enable full collision for static mesh (use complex collision as simple, double side), hid collision mesh on level. And it works! Even for high-resolution mesh (now I use mesh exported from LOD2 Landscape).
It is ridiculous, but I made level only for tests and don’t want recreate it with different resolution.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.