The objects use the same material must use the same texture for lightmap??
e.g.
there are two objects named “obj01” and “obj2” use a same material,and they have diffrent lightmaps.Import them into the
unity3d,it looks they can’t use diffrent lightmaps.How to resolve it except merge them to one.
:?: :?: :?: :?: :?:
To support you, i’ve the same doubt
Someone helps?
how about create a second material from existing one and replace the lightmap?
I just combine the objects in Maya and create a 2nd UV set and assign an auto-mapping on it and bake the lighting into the 2nd UV set. Then I separate the objects in Maya before import into Unity. This way the objects have the same material and lightmap, but the lighting info is different on every object. I hope that helps.
:?: :?:
Thank you very much,and I have some problems
Did you use this script ?
http://www.unifycommunity.com/wiki/index.php?title=UVTransfer
After I used it,I can’t use diffrent lightmaps in the same material and texture of objects…
You need to make new materials with different textures and assign those new materials to the appropriate meshes.
No, I have never used that script.
These are the steps I use:
In Maya:
- Assign UV’s to the one object
- Transfer the UV’s onto the other objects.
- Combine the meshes
- Assign 2nd UV set to the combined object
- Perform Automatic Mapping
- Bake Lighting onto texture using the 2nd UV set
- Separate the objects
- Rename them
- Export them
In Unity:
- Using Lightmap shader, make sure the diffuse texture and lightmap texture are in the appropriate slots.
Now you have 20 uniquely lit crate objects with only 1 material, 1 diffuse map, and 1 lightmap.
That is the way I do it, but you could also just make 20 different materials each with it’s own lightmap.
Thanks very much, everyone,I am going to try it again.