Can't render leaves in correct order (The ones in the back render ontop of those close)

A picture tells a thousand words so here’s a gif:
https://gyazo.com/8e4e10a2d1b6db59a52c3bf845aee40d

I can’t get the leaves to render properly.
As you can see, the faces that are furthest away from the camera render ontop of those who are closest to the camera.

My setup is to have a BasePart with a SpecialMesh inside.
image
The mesh has only meshid, no texture. Then I add a Texture or a Decal to the part and set the part transparency to 1.

Am I doing this wrong? How do other people render these things correctly?

1 Like

Okay, so I don’t know for sure, (I’d have to analyze it a bit closer) but I think your problem is that the textures are only on one side of all the meshes. I don’t know exactly how it works because I don’t use textures that much, but you’d have to find a way to make the texture on the opposite side of the mesh. Again, I don’t know how it works because it’s a mesh that doesn’t have any depth (I’m assuming, at least) but if your texture is on the front side then maybe duplicate it and set the ‘Face’ property to back. Or if it’s left, make it right. Or if it’s top, make it back.

Get back to me if this works.

2 Likes

I’ve duplicated the mesh and flipped the faces yet it doesn’t help. I think

This is the issue. Roblox simply doesnt seem to support it :confused:

Do you think you could make a .rbx file that I can tinker with? I doubt that Roblox doesn’t support it. Otherwise a lot of showcase places would look a lot different.

This was a bought model, I can’t share it sorry :confused:
You have a showcase that managed to do this properly that I can inspect?

If it was a bought model then I feel bad for you. I’m 99% sure what you’re looking for is totally possible.
This showcase features many trees and bushes that look perfect.

I have another idea. Your meshes are maybe only one sided. As in they don’t have a physical bottom side, only a topside.

This is known as depth-sorting errors, and due to how Roblox handles and renders objects that are transparent, this is intentional for mobile performance.

However there is a feature request to make this actually viable if you’d like to support it:

2 Likes