Transparency clipping or something

So I’ve been working on one of my games when I came across a problem in obj files.

Screenshot 2023-04-05 192703

Thats a picture of 2 imported objs’ into three js the left one is transparent, however if I turn my camera down it looks like its clipping or something

Screenshot 2023-04-05 192703

thats the picture of the transparent obj but when I put ‘transparent: true’ to my obj’s material it just does it even without opacity.

Normals on the cube are most likely flipped (example.) What you should do - is fix the normals in Blender or another 3D program. What you can do is just set side: Three.DoubleSide on the material - and it should work just fine :relieved:

alright imma check

1 Like

it dont work

1 Like

alright so i did the flipping and stuff but it doesnt work when i turn the camera down it starts clipping.

It’s going to cause lots of problems using .transparent = true on a material without opacity… transparent objects are are very sensitive to drawing order. Make sure that no materials are transparent unless they absolutely need to be.

If you need the object to be transparent though, maybe show the bounding box of each mesh in the scene (not just the glitchy one!) using BoxHelper? Everything is sorted by the center of its bounding box, if your larger mesh in the background is also transparent, then trying to sort one object inside another is going to lead to more problems.