Trying to re-create this in Node Material Editor

I don’t know if front facing is doing what I expect?
I am trying make it so it looks like fake liquid by cutting the mesh in half, have its back face showing, and color the backface a separate color.

basically Is there a way to just color the backface in the node material editor?

I am trying to re-create this https://i.imgur.com/CTSwHHv.png

https://nme.babylonjs.com/#D7FLLA

What you are doing is fine, the problem being that because you link the alpha input of the FragmentOutput block, the rendering system considers you want to display your object with transparency and so flag the object as “transparent”. It means it does not write to the depth buffer and because the faces are drawn in no particular order (in fact, they are drawn in their creation order), the display is all mixed up.

Instead, you should use the Discard block:

https://nme.babylonjs.com/#D7FLLA#2

This way, the object is not considered as transparent and is rendered with the depth buffer on.

1 Like

thank you!