Rendering multiple objects above the rest of the scene without rendering above each other in URP
Hello, I need to create a method for viewmodels in my game where the player's body and hands are rendered above all else. I am using the Universal Render Pipeline, Unity version 2021.2.0b11. I've been searching around for awhile trying to find an answer but nothing has worked well. I tried using overlays, but this presented a problem. Shadows from the environment did not affect the viewmodel. This makes the body look absolutely horrible when in a slightly dark region. So, this leads me to using the Depth Write and Depth Test feature in the Shader Graph. I set the write to Force Enabled, and test to Always. This successfully renders my viewmodel above everything.. even itself.
The gray color I doubt is related, but I don't know what causes that either. Anyways, this shows the problem that the several parts of the viewmodel are rendering over each other, which is not ideal. Is there any way to use this method and prevent the several parts from rendering over each other? Is there an alternate method that allows you to have lighting while still rendering the whole viewmodel over everything? And for more information, here's the shader itself in the Shader Graph:
Your answer
![](https://koobas.hobune.stream/wayback/20220613043048im_/https://answers.unity.com/themes/thub/images/avi.jpg)