- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Meshing >
- [SOLVED] Sims3 object import/export (Milkshape) breaking normals and UV maps
- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Meshing >
- [SOLVED] Sims3 object import/export (Milkshape) breaking normals and UV maps
Posts: 11,006
Thanks: 423049 in 1121 Posts
I'm meshing/mapping in blender; I only do the Milkshape circus in order to get stuff into the game.
Here's how it looks after importing an obj (I can save it and re-open it, it always looks like this):
Here's how it looks after exporting to .sc3asc, making a new file and importing the same .sc3asc again (AutoSmooth was always off; I did not do anything in Milkshape – just imported, renamed the groups, and exported):
This is how it looks in game: normals are broken; smooth edges; also the UV seems messed up in places:
This is how it looks in blender – normals look OK; everything is expicitely set to Solid (and the stretched face on the one leg is definitely not in my map):
I tried to export without normals from blender; while that seems to get rid of the messy smoothing, it completely breaks the lighting so that's not a solution:
Is this a known issue? Any idea how to get rid of it? Is there any way to view/edit the normals in Milkshape at all? I didn't find anything, so all I can go by is the render preview.
This is blender 2.46, Milkshape 1.8.4, S3OC 0912-13-1531, S3PE 0912-13-1729.
Another, unrelated problem: how does one edit the shape/behaviour of the indoor dropshadow? This is one of the "0001" LODs, correct? See the "shadows" screenshot – seems like both my object and the one that I've cloned it from are using the wrong shadow (which is actually the right one for mine, only that it doesn't change direction with the actual object).
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 2,932
Thanks: 15576 in 28 Posts
Tools/Selection Editor
What is this issue you're having with the indoor shadow? It should be the one that is in the first MLOD. The normal looking model that has a shadow. This one is the one that's giving you trouble?
Which table is your clone?
Posts: 11,006
Thanks: 423049 in 1121 Posts
Re. the indoor shadow, the issue I'm seeing is that on the maxis table (left), the shadow has both the wrong shape and the wrong orientation, and on mine (right) it has the wrong orientation. See how the table is at an angle, but the shadow isn't? (That said, I forgot to check whether this also happens with lighting/shadow on High – I had it on Medium when I took the screenshot)
ETA: i'm not talking about the static dropshadow texture – that one's fine –, but about the one that's calculated in-game.
My table is the one in all of the pics .. the small, square one.
ETA: re. the directX stuff, is it this one: http://www.microsoft.com/downloads/...&displaylang=en ?
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
"Before" is the original map; the missing/stretched faces on the front left leg are selected on that one. "After" is the exported-imported-exported-imported one. Legs are haywire, and one of the faces of the table top side exploded all over the place (I didn't even see that in game, but it's on the backside ..).
The faces on the front side of the tabletop are intact on the UV map though, so I guess there must be something else still wrong. (With "front" I mean the side with the drawer.)
I have no idea how to fix this, if it's due to the export/import =/.
ETA: i just checked, for comparison: importing an obj in Milkshape, exporting as obj and importing in blender again leaves the UV intact. So it definitely has something to do with the Sims-3-exporting.
Is there any way to splice an UV map out of an obj and into the TS3 filepiles somehow?
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
Also, if split vs. non-split vertices are the issue, could it help to split vertices in blender? I think I already tried that once, because the Sims 3 export thing always told me "123 vertices split" and I thought maybe it has a problem with that. I dont remember that I saw any effect, but at that time I was trying to fix a different problem so maybe I just didn't pay attention.
And a new UV map + texture wouldn't affect the borky normals and the smooth edges, or would it? I'm not really sure whether these are related problems or not.
Also, a blender question for you (cmomoney), if you don't mind: is there a way to tell blender to use less noise when baking a texture? If I knew how to do that, that would make it easier to experiment with remapping – right now I'm baking the shadows and then I blur/soften it in Photoshop (which means I'd have to go and re-blur every time I re-bake because the mapping is changed) – the noise was great for TS2, but in TS3 it looks a bit shitty.
I know that a blender export thingy is apparently in the works (yay!), but I don't think this is a blender issue. The files in question are fine as far as Milkshape is concerned, it's only the export/import that is the problem.
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
As for the baking, are you using the "Approximate" method?
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
What's "Approximate" method? I made the texture with Render > Bake Render Meshes > Ambient Occlusion. This was perfect for TS2, but for TS3 the noise is too much. Attaching a comparison of original vs. retouched, so that you can see what I'm after (I think the bottom of the "body" of the table was black in the original because those faces were underneath the bottom-of-tabletop faces on the map).
ETA: ooh, I think I found it! =) http://www.katsbits.com/htm/tutoria...ing_terrain.htm -- I didn't have the World panel enabled, that's why I never saw this. Cool cool.
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
"Mark seam" (CTRL+E in edit mode) tells Blender where to cut the mesh when unwrapping. You select an edge, mark seam, and Blender unwraps the mesh based on the edges you marked.
Under the World button and the AO tab, it gives you the setting for how to render the AO. The default method is Raytracing, which gives you very accurate results, and noise. Change that to Approximate and you should get the results your looking for. The other settings kinda depend on the difference between your high-res mesh and the low one.
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
Re. seams: ah, you mean seams in the mesh. I didn't do that at all, since that mesh is basically just a couple of cubes (plus 2 cylinders for the handle) .. I just hit U > cube projection, then moved the faces where I wanted, then made the texture. The weird thing is that of the 4 sides of the tabletop, 3 work and one doesn't; of the legs (which are cubes minus the top and bottom faces) I think two are intact, the other two have one or two sides messed up .. but they're all mapped the same. For the legs I made one cube, then duplicated that 3 times, then removed the unnecessary faces of all .. and the whole thing is unwrapped all in one go. In other words, I can't find a difference between the legs that work and the ones that don't.
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
Marking seams isn't really necessary. It just helps you control the unwrap.
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
".obj files are laid out differently from the way the game requires vertices to be laid out. You cannot share vertices in this game between faces if they do not share identical UV locations."
So in other words, when I move faces on the map, I must split the corresponding vertices in the mesh – is that right? So that instead of 2 triangles sharing one edge (2 verts) = 4 verts, I now make it 3 separate triangles (6 verts) with 2 verts each that just happen to be at the same location in space? Continuous planes in the mesh must be continous in the map too? (Just trying to make sure I understand it =)
I actually already tested splitting all vertices in the entire mesh .. but maybe I didn't notice that it fixed the map, because that was a version I exported without normals (which breaks the lighting) so I filed it under "not a solution".
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
Thanks for your help, so far … I'm curious to see whether it works (and maybe fixes the normals/smoothing problem too).
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 11,006
Thanks: 423049 in 1121 Posts
SplitEdges did the trick. The legs are now basically four separate planes each (just splitting them once wasn't enough apparently), which feels a bit silly .. but it's still just over 200 vertices which is OK for that kind of object, I guess.
The indoor shadows (not the static ones) are still weird though, but I'm not sure atm whether the EAxian ones aren't just as weird.
Now on to tweaking the presets ..
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 1,740
Thanks: 107805 in 53 Posts
| (• ◡•)| (❍ᴥ❍ʋ) [◕ ‿ ◕]
Posts: 11,006
Thanks: 423049 in 1121 Posts
Because those crucial bits of info (by Wes) are buried in an old thread on *body meshes* -- most likely object makers won't see it there.
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Who Posted
|