im want to add an overlay material outline that shows when players get close to the actor but as seen in the below screen shot of the overlay material, i followed a simple tutorial but the result were not as excpected and i do not know why can some ojne help please?
Hello there @MadLed!
From your shader setup, I would test by inverting the order of the TwoSidedSign, pass it through MinusOne first, then feed it to Multiply, along with a float parameter to control the intensity:
Also, make sure your target mesh has Nanite disabled, as it’s doesn’t interact quite well with Overlays, or doesn’t show up at all (here, same overlay applied, left square has Nanite OFF, right square has it ON):
You can find all the steps on the UE guide below:
the mesh already has nanite disabled and i tried to do it the way you told me to and it still game me the same result
and when i try to increase the thickness this happenes
im thinking maybe because the model is low poly or because there is something wrong with its normals, but im not sure
Hello again!
That’s a quite bizzare effect you are getting in your screenshot. And considering your blueprint setup looks correct when compared to the guide and the sample I shared in the previous post, it means the issue shouldn’t be there (at least with the information provided so far).
There’s something outside the material affecting this, and that could be the low poly model, or how it’s normals are being handled. Checking around the community, the overlay effect can be affected when used with a low poly model, but testing with the engine on my end, I was unable to reproduce the effect you are getting, even using a simple cube. What I did find, was how to resolve potential normal conflicts. Open your mesh, check the Build Settings, and ensure the following parameters are enabled:
Once they are all checked, apply changes, save, and test your material again. If the issue persists, at that point I would suggest constructing an alternative material, to rule out any faulty parameter we are not seeing. To do so, follow the video guide below, step by step:
Adding an update for your scenario, after further testing, I managed to reproduce the “split up” effect on a material overlay:
The key is how Nanite was disabled in the project. If the switch is done per mesh basis (meaning, opening each mesh and disabling Nanite support), no issue should take place.
Instead, if it was disabled globally from Project Settings, under Engine > Rendering, while the affected assets still have “Enable Nanite Support” checked in, then the split up effect will appear.
If this is the case, I would suggest avoiding the gobal check off for Nanite, and to disable it per mesh basis, which should prevent the glitch in your overlays.
Hi @brs-sebascova sorry for the late reply and thank you for youe effort in trying to help me
but i checked and saw that nanite was already enabled in the project settings and disabled in the mesh that im testing and it gave the same split up effect no change at all. I even tried disabling the nanite in project settings and enabling it in the mesh and disabling it but still no change.
i have no idea how to fix this and im starting to give up on this idea all together :,)
With hard edges, the adjacent normals point in different directions, causing the faces to appear separated.
While using smooth edges resolves this issue, it changes the visual appearance. I think a good solution is to separate the normals used for lighting from those used for outlines.
In the attached image, you can see how I baked the smooth edge normals for the outline into vertex colors and used them in place of VertexNormalWS.













