Mesh becomes transparent on viewport settings change

here is an example of actions sequence that display the bug:


it happens pretty wildly, and seems to also involve Lit/Unlit, wireframe etc

It only happens on this specific project since i have migrated from 4.16->4.17->4.18

there are also other broken things, on which i am not sure they are connected to that specific bug, but here they are:

  1. dragging new assets from content browser into the viewport always spawns the items in the location of the camera
  2. i cannot move any objects by clicking and dragging their axes, but shift+drag works for some reason
  3. terrains and some other objects seem to have some geometry rendering bugged up pretty badly:

  • you may see the rifle renders hidden geometry instead the unhidden
  • parts of the landscape mesh do the same behaviour
  • distant hidden (behind the landscape) plane mesh for some reason serves as a renderer plane for other part of the viewport, even though the mesh doesn’t even have any material assigned.


Settings -> Project Settings -> search for "Near Clip Plane" -> set the value to something different than 0.

(if you are not familiar with it, i advice to read about it before you put another bad value)

I don’t know why did it save 0 in the place, but it has fixed everything.

Thank you so much! I set it to zero too and when I reloaded my project, everything became translucent and I started freaking out! You really saved me!

np glad to help ;]