- Home /
Trouble with UV Mapping
Hello All,
I'm fairly new to Unity and game development, and I'm having a problem with my avatar creator. I am using the same kind of system as the free demo-project, where I build a single Skinned Mesh Renderer out of multiple mesh pieces. The problem I'm having right now is that a single hair mesh when it's texture is applied, the UV mapping is wrong and the texture looks all funky on the mesh. If I take the individual mesh into a scene and apply any of it's textures no problem, it is only when the avatar is built that its actually messing up. All of the other meshes/textures work except for this one. I know this is a very vague question, but can you think of anything that I could check for troubleshooting wise? Any help no matter how minute would be awesome!
Thanks Hans
Answer by testure · Jul 27, 2011 at 02:21 PM
first off- i think your terminology is off, because you can't lightmap a skinned mesh.. only static.
I can infer from your post that your lighting is not looking correctly. This is probably because you have a vertex lit shader mixed in with shaders that are pixel lit. For your hair, make sure you're using a cutout shader and not a 'transparency' shader. cutout shaders are pixel lit, but can only do binary transparency. as far as your uv's being off, there's no way to tell without seeing the mesh. just verify that you have the correct textures applied to the right materials, and the right materials applied to the right polygons :)
Sorry your correct my ter$$anonymous$$ology was off I have edit my original question, what I meant was the UV map is thrown off not the light mapping. The shader itself doesn't seem to be the problem the the lighting is fine in the scene but the texture itself isn't sitting correctly on the mesh.
Is there any reason you can think of why apply the texture to the mesh through a script would throw off the UV map? When I check the avatar in the scene it is the proper mesh and the proper texture. They aren't being mismatched
I marked this answered because the problem is no longer persisting, I redid the mesh and it works out so the old UV map must have been incorrect