Unity 3D Text becomes Word Cubes

954 views Asked by At

As the image shows, my 3D Text keeps disappearing from my scene when I click Play, and then when I zoom in, this is what I see.

When I exit the Play scene, it stays like that till I Ctrl+S and Save on which is returns to its proper text form.

Is there something I don't know? This happens even when I deploy my app ona device. These words are never seen because of this.

Using:

Unity 5.0.3p1 (32bit)

But I've had this problem with all version starting from Unity 4.x

enter image description here enter image description here enter image description here

My Hierarchy:

enter image description here

2

There are 2 answers

1
Emilio Martinez On BEST ANSWER

Your problem is having a MeshFilter on the same GameObject as your TextMesh

What you are seeing is the MeshRenderer drawing the wrong mesh, but using the font's material. Those seemingly random letters is what a font texture atlas actually looks like when textured on a cube. What mesh is chosen might as well be random, and with bad luck this kind of things might go undetected on the editor but show up on the builds.

This situation has already been submitted as an issue, but marked as Status By Design. Quoting directly from the issue tracker page:

TextMesh mesh is wrong when MeshFilter present on same GameObject.

This is expected behavior.

MeshFilter and TextMesh are both components that rely on a MeshRenderer component to render the mesh. When they are both present, they are conflicting over which one gets to set the mesh that the MeshRenderer should use.

That said, we should not allow a MeshFilter and TextMesh on the same GameObject because it is not supported anyway. We'll file a separate bug bug on that.

5
Reasurria On

I think the RectTransform is messing things up. Right click and save the settings of your text mesh. Then use the menus at the top of Unity to add a new, clean 3D text mesh and paste the component settings into that one. Don't choose the UI text if you want to use the 3D text. There is a separate option for the 3D text.