UE 5.3: Issues with packaged game: broken nanite landscape and shadows

Hi. I’ve got a problem while trying nanite landscape. While i run the game in editor everything works fine, but when i pack for windows… The screenshot will show it better:


Missing triangles in landscape can be fixed with disabling nanite for it (not an option though). Shadows… I don’t know what causes them. Tried to disable hardware ray tracing - didn’t help. Maybe made even worse (my gpu doesn’t have rtx anyway). Also note the strange thing in top left corner of the screen. Also no idea why this happened.

Once again - these issues are present only in packaged game, in editor everything works well. Any ideas what’s wrong and how to fix it?

5 Likes

I made an investigation with simplest possible project and found that exactly nanite tesselation causes that lost triangles.

(can’t post more than one screenshot, but here was another image of broken terrain in default 1st person project)

But if i remove this displacement connection (shown with red) - everything becomes well (except i don’t want my landscape to be flat and boring):


Will keep on trying to reproduce those shadow and strange-square-in-the-corner issues.

Have anyone made successful packaging of the project with nanite terrain displacement in use?

You shouldn’t use nanite and procedurally displaced shading at the same time.
Nanite takes the place of this – if you want your mesh to “not be flat and boring,” then you should tesselate it to the point where it isn’t flat and boring. Make it have lots of little triangles, with carefully hand-sculpted variation! That’s what Nanite is for.

Or you can turn off nanite on this mesh and use shader displacement.

Why there’s not a warning when you do this? No idea.

So, how can i use shader displacement without nanite in correct way? I disabled nanite for the mesh (tried with both landscape and default cube), and it became flat even if i connect “displacement” link in material graph. Note, that before i placed

r.Nanite.AllowTessellation=1
r.Nanite.Tessellation=1

in my DefaultEngine.ini, i did not even have the displacement port in material node. Looks like i’m doing something wrong, but what is the right way?

1 Like

If it becomes “flat,” then maybe the mesh just isn’t tesselated enough?
Displacement only displaces vertices that actually exist. Unreal Engine doesn’t generate tesselated additional triangles on regular meshes. (I seem to recall that older versions used to, but it was problematic and got dropped.)

I think the best option for you, is to massively tesselate your model, and add all the variation you need in the model, and then turn on Nanite so the model runs at good performance. The point of Nanite is not “make flat models look good,” but instead, “make very detailed models run fast.”

Yes, for my regular models i can do it in blender, just like you say, but what about landscape? All those videos on youtube about tessellation in 5.3 looks great, and it really is, but only in editor. No one tried this with packaged project?

UPD: It seems that the problem is present only with landscape. Normal mesh can be nanite-displaced without any issues.

1 Like

In my opinion, there are clear issues in that screen shot. Look at the gaps along the corners!

Procedural displacement is really quite hard to get good.
It’s much more robust to model it in whatever modeling tool and let Nanite take care of simplification.

You can push the Landscape module a bit by subdividing at, say, 20 cm instead of 100 cm, but if you need more resolution than that, you should either add custom crafted meshes where it’s needed, or build your entire terrain as a sequence of custom meshes, and throw them at Nanite.

Generally, though, landscapes are covered by underbrush, which hides the somewhat-coarse triangles, and transitions are artfully masked with prop meshes and random greeble.

Developing current-age AAA game looks will require a lot of different thinking than the best practices of one generation ago, or what was leading edge two generations ago … The rules, and what approaches actually work, have changed.

Same issue here, did you solve it?
I’m also using tessellation and got the exact same issue, even the weird square in the corner…

No. I think we have to write a bug report to dev and wait for 5.4. Also I’ve noticed the same behavior in editor appearing for a few seconds after clicking “apply” in material edit window, while engine rebuilding something. Don’t know how this observation can help, but anyway…

1 Like

Do you also have the error ‘Landscape: Actors with physical material needs to be rebuilt’ in the editor?

I had it once, try to click on “(re)build data” in landscape properties window.

yeah lol, that was the first thing I tried. But it seems to be another glitch, just thought it might be related

Exacly same problem with displacement when packaged.
Tried Building Textures, Landscape, Landscape Nanite, HLODs.
I hope somebody will find way to fixed.

Hi,

I have the exact same issue with the packaged game!

1 Like

My Landscape is also broken in packaged builds when using nanite. Looks exactly the same like in the screenshots from SElisei and imonedesign above. When using play in editor or even standalone game it works like a charm. Anyone has a solution for this?

I’m almost afraid to ask, but did you guys find a solution?
I tried to package my projecty when I moved it from 5.2.1 to 5.3.1 and in a packaged build without Nanite enabled my whole LAndscape is gone…
Landscape Splines still exist. but no Landscape… No idea what’s goign on…

No luck yet! still the same issue, I wonder if it’s just a bug that they can fix in the next update.

1 Like

And if they will :slight_smile:

Today this started to happen in editor as well. Before that it was working fine there, but after some terrain re-work in WorldMachine and a reimport the bug is in Editor Mode as well.

Hi, I had the same issue. Putting a component mask between the make material attributes and the output seemed to fix my issues. I dont know if thats the correct fix but it worked…
It would be great to know what the actual issue is here, if its a bug or incorrect set-up.

5 Likes