Jump to content

CC Troubleshooting Help


Recommended Posts

Posted (edited)

Hello! I'm opening this thread so I don't clog the one where this conversation began.
 

EDIT: I'm adding an index to this post for easier navigation/search.

 

Glossary of terms: 3D names for each part that you need to know to work with any software. Applies to Blender, but also Maya and the rest.


This post: Curtom content and textures: examples of both uv_1 and uv_0 corrections.


Texture baking 1: preparing the file (materials, render, samples number).

 

Mesh deformation and uv_1 setting: placing your mesh uvs along the uv_1 map for correct deformation from sliders.


Mesh manipulation 1: placing the cuts on the best places to follow EA's models.


Texture baking 2: preparing your object for texturing from scratch. Example is NOT a clothing item. Please don't follow the UV setting instruction fro CAS items.


I want to start saying that I know that it's bad manners to edit other people's meshes without asking first. That's why I won't be sharing the files that I'm going to talk about. Everything seen here is done for personal use only.

However, I know that can't be the only one who's found these problems. For example, you download something that looks really pretty, try it on on one of your own sims... only for it to deform in wrong, unexpected ways if your sim has a bigger frame than the model they used.

I've come to find that most content that annoys me this way is any neck accessories. And I am unhappy about it, I want my bigger sims to be able to wear them too!

So I realized that would be an excellent practice for troubleshooting for me. I learn better by fixing than by creating from scratch.

 

This is SLYD's Silk Choker you can find in TSR, before and after my edits:
 

Spoiler

comparing.png.667476ffa62608bf3522d3ebd317bb78.png

 

It's a solid improvement. I have some fine tuning left to do, but the bulk of the work is done.

 

There were two steps for it, and I must admit, I'm not entirely sure of how both influence the object itself yet. I transfered the vertex weights to the mesh using the Data Transfer Modifier, and also created the missing uv_1. I then moved the whole new set of uvs so they would match the right place over the body mesh uvs. That is probably the most tedious part of it all, especially with an object that goes around the whole sim like this one.


Keep in mind, at first it's a slow and frustrating process if you're not familiar with anything you're doing. In my case, Blender was a mystery to me, but I'm lucky, I have a solid base, I am familiar with 3D for videogames already. I understood the problems just by seeing them. And that's why I want to invite anyone with similar troubles who want to learn to use this thread. I may be slow responding, but I will do my best to guide anyone interested on doing the same thing. I don't want to have the first post full of step-by-step pictures, but Blender tutorials are easier to follow with visual instructions.


Another item that I'm working on is Azmodan's Strap-on. This one is subtler, extra difficult to notice, as it's really well made. But one of the strap bands have broken uvs. And I want to make recolors, so this issue made them look wrong. Here are pictures of the original with its texture, and a checkers so you can see how the bottom's uvs are not fully unfolded, that's why it shows a single color for each face instead of the chekers.

 

Spoiler

 

 

 

003.PNG.213d4b70361c2141f377883c54f24b6a.PNG004.PNG.7f6afa1613d20ef414031324d7e4d95e.PNG

 

So I put myself to work on straightening them, and stitching the mesh while on it so every part was a single uv island. That makes it neater to create new textures. Below are the results, waiting for a few small tweaks to be ready. Right now they're not baked yet, so it's all either a leather texture I got or plain colors using several Principled BSDF, one for each type of material you can see here: Leather, Metallic, Dildo. Once I'm happy, I'll bake it, which means Blender will create a single Diffuse map with all three materials' info and cut it to the uvs shapes only, leaving the rest blank so there's no bleeding on other objects.
 

Spoiler

 

005.PNG.c960b2da478a252649c7375d52c99494.PNG001.PNG.c38f2a0af1dd4bb33e18d1b672d63c04.PNG

 

 

Of course, all here can be used by anyone creating their own cc from scratch too. If you're stuck with something looking wrong, drop it here so we can try to fix it.

(@Simite here you go, examples of what I can do/am doing. I am now learning how to make Specular and Shadow maps, I want the metallic parts to be shiny in-game too. You mentioned working on diffuses rn, let me know if I can help you. I'd like to do it here so others can learn too, but dms are fine too.)

Edited by Mimi-e
added an index to first post
Posted

I really like this idea, I would love to be able to hash some things out in public place so that everyone can learn from the parts that are relevant to them. I've quickly made up a pumpkin mesh and applied some basic materials and a solidify modifier, just a little something we can pass back and forth and show examples or practice different methods and results etc.

I had a little bit of testing on baking textures too the mesh on other objects I am working on and the materials did not look anything like they should have after baking, not to mention the quality of the defuse produced was pretty poor so hopefully you can help me figure out the settings I should be using for better results.

 

I made this mesh in Blender 2.79 but I don't mind if you would rather use a higher version of blender, I just havn't had much luck uploading meshes into s4s with blender 3.3 even with s4s beta Star.

 

Pumpkin_Practise.blend

Posted

It's not easy to make CC fit all kind of body shape.

If I'm not mistaken the uv_1 is responsible for making the sliders work. If an object can deform it should have this uv and be unwrapped. I usually transfer it from EA's content.

 

And here is a good post about the speculars in The Sims 4 : http://teanmoon.blogspot.com/2016/04/the-specular-texture.html

 

Feel free to ask questions if you're stuck somewhere.

Posted
On 10/25/2022 at 11:24 PM, Simite said:

I really like this idea, I would love to be able to hash some things out in public place so that everyone can learn from the parts that are relevant to them. I've quickly made up a pumpkin mesh and applied some basic materials and a solidify modifier, just a little something we can pass back and forth and show examples or practice different methods and results etc.

I had a little bit of testing on baking textures too the mesh on other objects I am working on and the materials did not look anything like they should have after baking, not to mention the quality of the defuse produced was pretty poor so hopefully you can help me figure out the settings I should be using for better results.

 

I made this mesh in Blender 2.79 but I don't mind if you would rather use a higher version of blender, I just havn't had much luck uploading meshes into s4s with blender 3.3 even with s4s beta Star.

 

Pumpkin_Practise.blend 921.91 kB · 2 downloads


That's a lovely pumpkin! And oooh, I didn't know that modifier yet, that's so handy! Hmmmm, I wonder what happens if I unfold the UVs before applying the modifier. I will try that on the side, and share when I know. I find the 2.79 interface confusing, so I'm going to go up, thanks for offering! We can look on what troubles you're finding with it together too, I have run into a few already, but all got ironed out.

So, texture baking! What do you mean nothing looked like they should after baking? Did they look too dark? Or something else? Oh, and really important and related to the above, you HAVE to Apply the modifier before baking any texture! Blender needs to have all of the topology's UVs cut and ready so it can gives you a proper map. The option to Apply is here, I'm showing bc that tiny arrow is so easy to miss, took me hours to find:

image.png.8d43718ae74363b9be4ac3ce62939594.png

(and yes, some will only be applicable from Object Mode, please remember this, as maybe it will allow you to click on it but no result will show. So Undo and try again from Object mode to make sure that's not it.)


Reading what you describe about baking issues, first comes to mind is that you're baking with the Direct and Indirect light influences ticked. Sho they're being saved with Cycles light system. They of course look good on Blender. But because you're going to use these textures in another graphic motor, the one TS4 has, they won't look the same in the game.

So let me repeat this, the way Blender bakes specular maps is NOT compatible with TS4. They won't look the same.

TS4 uses a very particular, and clever, way to tell objects how to shine and how much by the RGB+A channels. Blender bakes the specular in a more standard way, BW.

The link Vthena shared about specular is a good one, and I have been looking at this one to understand how they work: https://www.tumblr.com/needleworkreve/663045890723954688/these-are-the-results-of-my-in-depth-look-into-how

 

Then, there's resolution. What size are you saving your files in? The HQ recommended sizes are here https://sims4hq.tumblr.com/makecompatible

 

If you're setting the resolution correctly, then the low quality is due to having way too few Render Samplers. Check here what number do you have.

image.png.a222db683a233003ae66c265979ece41.png

I see 128 set for the pumpkin, but those may be too few for a good 4K bake. I find this video very informative, even if he's baking the Ambient Occlusion (similar to what TS4/S4S calls Shadows), he is using just 2048x2048 and still uses a high number of Samples, plus explains the importance of the Margin value.
 


I highly recommend using an AO map in clothing texturing. But I think that's enough information for a post, I'll wait for your answers so we can see how to best fix the problems you're finding.
 

Posted
On 10/26/2022 at 6:45 AM, Vthena said:

It's not easy to make CC fit all kind of body shape.

If I'm not mistaken the uv_1 is responsible for making the sliders work. If an object can deform it should have this uv and be unwrapped. I usually transfer it from EA's content.

 

And here is a good post about the speculars in The Sims 4 : http://teanmoon.blogspot.com/2016/04/the-specular-texture.html

 

Feel free to ask questions if you're stuck somewhere.


You're correct! But transfering unique meshes' layout from EA's content won't give you the best results. What it's best is to open these textures on Blender on the UV Editor, with the uv_1 selected, and aligning vertex to match the place they have on the model.

Spoiler


uv_1male.png.6babefb27d59f82d0991a041078fb0fe.pnguv_1female.png.5d1fed0dbc0ca90d15d38bb83f0898c1.png



That's how I corrected the sample choker's deformation in the example above. This is how uv_1 looks before resizing:

image.png.d13175ba5788fd300fb67a71a1c9c33f.png

See how it matches the placement, pkus has no stretched out edges between sides? The object is cylindrical so it would do that if I just unwrapped it without cuts/seams. I went and cut the UV at the same place where the guide tecture is divided, at the back of the neck, just along the middle. It stretches out matching perfectly now.

The next step, however, is one that I've seen Tea'n'Moon and others recommend, but haven't really tried myseft if it's necessary. They follow EA's steps, so once it's all lined up like this, you have to Scale by 2 on Y axis, then Move 0.5 to the lext on the X axis, like this:

image.png.3bc57f95e5dd7fca8e841a8db9214a68.png

However! What most people don't know about UV islands and texture relationship is, they repeat and tile. So I have to wonder if this is necessary or the game can tell that this UV must be stretched or squeezed to conform to how the game handles the sliders (which is really complex, I was reading about it this weekend and my head wanted to explode Bless CMar for their programs!).

Vthena, would you mind if I open one of your clothing items and take a look, then post possible improvements here? I have some of your items and you do a great job with sliders, I'm curious to see how they're made after you mentioned you transfer it.

Posted
1 hour ago, Mimi-e said:

Vthena, would you mind if I open one of your clothing items and take a look, then post possible improvements here? I have some of your items and you do a great job with sliders, I'm curious to see how they're made after you mentioned you transfer it.

 

Feel free to open my CC to see how it's made. But the topology of my meshes is terrible so don't take inspiration from that ? (I couldn't figure out a better way to keep the same UV across different outfit, so the mesh is straight from Marvelous designer.)

 

 

 

Posted (edited)

Thank you!

 

Okay, okay, have you even heard of Topogun? It's an easy way to make low poly, clean meshes on top of high resolution ones straight out of ZBrush and Marvelous Designer I know. But it's not free, so if you can't get your hands on it, the second best thing is this, Retopoflow for Blender: https://github.com/CGCookie/retopoflow/releases

I'm learning my way around it, so I'll have to come back to it when I've gotten used to it myself, but this tutorial I'm watching is really good, so I'll share it:

 

With that said, I'm looking at your Jenny Top V1 and I see it's divided in 6 parts, with two seams goind down the armhole. Is it because that's how it was made in Marvelous Designer? I also see some faces that are loose, not merged with the piece they belong to.
 

Spoiler

image.png.c0f2e48f104432365fcddc604021cf3d.png



That is an issue because often it means it will have the normals of those faces behaving a bit strange, and it may show some unwanted shadows along the seams of those detached faces.

I have seen that some people are very scared of touching the mesh they get out of MD, to the point of deleting the undermesh instead of just mofing the faces a bit outwards. Or merging them in fear it will ruin the object somehow. But there's no need for that, usually no data is lost if you merge, and Blender handles the UV islands without issues even if you reattach those faces.

What I do to check is this: from Edit mode, Vertex Selection activated, I click on a single vertex, then Ctrl + so the selection expands. Hold it until it's covering all of it. That's how I discover these loose faces. So once I find them, I Shift Click them into the selection, either from Vertex Selection or, if it's on a seam and it's selecting the wrong vertex, Face Selection. I also recently discovered that if I hold Shift, I can select more modes at once!

image.png.4ffd96abff87547ee70d516ed1b4e3a2.png

To see the clothing item more clearly, sometimes it's a good idea to hide the mannequin. Vthena's piece has inner faces too because it has an open button version. So I'm going to hide it using the Ctrl + mentioned above in all parts of the mannequin mesh until it's all selected

 

Spoiler

image.png.dc6dbe955d98d8bb52eea87cc65560ec.png

 

Once it looks like this, hit H to Hide selected. (If it's hard to do, it may be easier to select the clothing instead, then hide the mannequin by hitting Shift H to hide unselected).

 

Spoiler

image.png.f53df0f85d8caaaa5a5abfbde38fcd8c.png


Now it's all hidden but the vest, and we can see inside. But nothing is gone,  if you need to see what's hidden again you just need to hit Alt H to show all hidden.

I'm going to select the front side first, plus the part down the armhole that's a separate part too. Once all of it is selected, includind the loose faces, hit M (merge), choose By Distance, then don't be worried if you see the mesh shrink. That means the distance value is too high. Open the menu ushown here, usually at the bottom left, and change it to 0.001, I usually don't lose any vertex with that value but the ones overlapping merge together without problem.

 

Spoiler

image.png.19b4ba914804cda44cbdc3a478ce4dce.png

image.png.8d613bdedce8e57be89971a73edd80da.png


If by any chance you have any vertex that should be overlapping out of place, don't worry! There's a very easy way to move it to the right place. Look for the magnet icon, Snap. Change it to Vertex, but don't activate it, keep it grey. Now, left click on the vertex to move, and without releasing the mouse, hold Ctrl, then slide the vertex over the one where it should be. Once you're close to it, you should see it snap itself to the target vertex. Now you can release all buttons.

 

Spoiler

image.png.d91fa9ccc91feed0a16756a8f82d411e.png

image.png.81cbf1c7cb5db0961839b84747831a6a.png

image.png.8ada5cda01b2aa21496fc44bff2858a2.png

 (this was an example, there was no hole in this mesh, but this face was detached so I used it to illustrate).


I repeat this merging step for all sides, AND the back. This has a very uneven center seam, so I'm going to merge it to fix it, then divide again. Once they are merged into one piece, I can use Shift V to slide vertex across its edges without moving them in any new dimension, so the mesh keeps its shape but the vertex move, so I can make a straight line on the back part.

 

Spoiler

image.png.52582311e1b64d07bdcc794dad87be05.png

image.png.3a6ef23cf11e082f2ae766fe13b2d8fb.png

 

Not perfect, but close enough. Also, note that while I am moving the mesh vertex, the UV is not being updated. There's probably a button to click for that but I don't know it yet. So some slight texture deformation may happen on this step. But it's okay, if it's too glaring it can be fixed. Also, Shift V WON'T work across different parts of a mesh, that's why I first merged them.


To divide the back once again, select the center vertex line. Then, go to Mesh >Split > Faces and Edges by Vertices

 

Spoiler

image.png.f4207c897fdfb3ced973fa1646b0b1e4.png

image.png.d4937b90913ada98e12505df53d879aa.png

image.png.055ab44c1f1bbb0fdd1a4e2d359ed2cf.png

(test move to show how it's now once again detached at the center.)

 

Time to take a look at the front! And there is something going on here that I want to look at better. There's a section with different coloration that doesn't look different on the texture. Ctrl + shows me that this part is detached from the front, but that's not all. There's actually two layers overlapping, that's what's showing the different coloration. It's probably intended for the open version, but I won't delete them. Instead, I'm going to move it inwards just a few points on both sides. BUT FIRST I'm going to deselect the vertices that overlap between sides, so they will stay in place and there's no gap. Hidding the buttons was very useful and also having no mannequin.


 

Spoiler

image.png.72a79f2c38ee2eab87234e4afdffd4fe.png

image.png.4c6de868cb845158d143be9291a1503a.png

image.png.4baf841ebe6f552cc3ef7e8292dbccdb.png

(interior view before)

 

Hah, seems like I've hit the file attachment limit, so part two down below.

 

 

Edited by Mimi-e
Posted
Spoiler

image.png.0b8111298c88a6a66a1f7a1ff77cf8d8.png

image.png.ff5c703a787c9437072cf62c41e854d8.png

(interior and exterior after)


One last thing before we take a look into uv_1. There are 4 buttons on this piece. And I know the rule that gets around is to not have overlapping UV islands. But that information is incomplete. You can, and in fact should, have shared islands, if the objects look the same way, like these 4 buttons. Shared UVs means shared texture space, and that leaves us free space for other things, or allows us to have a higher resolution version of it. This ALSO applies to sidef of clothing that are symmetricl, like the back part of this vest. I will show that next.

In fact, this piece uses that! The extra parts I just moved are in the same area, shared by them without issues. It is not the UV shared space but the MESH shared space that causes aberrations. So when making clothing items where we're putting geometry on both sides of it, it should be moved just slighly out of  the way, not sharing the same 3D space.


The vest is now divided in 4 parts, divided into fron and back, left and right sides, plus buttons. Let's take a look at the Diffuse texture map plus uv_0. Again, because this is a piece that's destined to be opened and show the nude chest area, Vthena has cleverly avoided to put the islands on top of the torso parts. Instead, they are either between the arms (back part's island) or on the extra space below, being careful to avoid the extra space for bottoms and shoes. I loaded a uv_0 layout guide in Blender to see it more clearly.


 

Spoiler

image.png.d7800182c7ed97f48d34de2e846aea47.png

image.png.3109786130c9d18096b1218921daf3c7.png

 

 The placement is great, even using the back space for the buttons, really clever! But! As I was mentioning, items that look the same don't need their unique space. So if it was me, I would do two things: move the buttons one on top of another, and and also put the side and back parts that are mirrored on top of each other. Let me show you how that would look like.


 

Spoiler

image.png.1059fdc99653234e1cc83de3e4b2fec9.png
(this is where I noticed that the buttons had very high detail at the center, I thought it was a single vertex but no! There's several loops! And they're scaled so much that the texture is being used by the EDGES of the buttons, not the faces. So I salected the loops and scaled them)

image.png.3e1f35333a83642807b1593d4bea261d.png

(right side is the face of the button, left side is the UV of it. Tiny!) And the bigger area is actually the backside of the button, not the edge)

image.png.86575b63cb0bcf031f2fbb628548c724.png

(scaled 24 times in all axis. It's squished at the top, but that's easy to fix by selecting the top half and scaling it vertically until it matches the bottom's curvature, then moving it.)

image.png.6f31c02855ef01abea0a7566ed7ea97d.png

(left is my uv edit result, right is original. Yes, this is barely noticeable with these dark colors, but it is important if we want to change them or include details like the stitches holding the buttons.)

image.png.5db37b7dfa67de4949389a697e694e08.png

(the buttons all piled on top of each other, and the model showing the texture in all four of them without any issue. Now there's space to make the button texture double in size if wanted, by editing it or rebaking)

 

Next, the back texture we edited. As mentioned, the UV was not synchronized, so the vertices in the center are not straightened. To fix this, I selected them on the mesh, then hit Crtl + once. With that selection, I selected those vertices on the UV editor, making sure to only add the ones at the center of the 3 columns. For this I used the Lasso selection so I would be selecting both sets at once. Then I scaled them to 0 on the X axis.


 

Spoiler

image.png.a52476af7bd23dd468a36a2ad96c5bdd.png

image.png.09ee6ccc06134e95b3cdbd71f6ae9ce2.png

image.png.ee636256742420ef0a932fcd403d701a.png

Now we can select one side only...

image.png.7a1d407ac6d0b9787538cc98101c058d.png

then Scale it to -1 on X

image.png.5d2b5bba7a7cca3a63e7ff7c7aacca0e.png

and slide it on top of it's mirrored side, Snapping it by Vertex Snap, while the mesh will still show a perfext texture, but we've saved more space!

image.png.59851138ed5cca83a41c26bebc7b40dc.png

if we wanted to, we could scale by almost 2.2, increasing resolution once again.

 

Please notice that even if the mesh was merged, the islands didn't change at all. So the textures can stay on different places if there are space limitations, like on this one and basically any clothing we want to have good resolution but show skin. So mirroring then overlapping as many islands as we can will free us space.

 

Time for uv_1 now, on the following post.

Posted

My fist step for uv_1 is always loading the reference square texture. Once that's loaded on the UV editior, I go to Object Data Properties >UV Maps and select it. Sometimes I've found it to be missing, and as you can imagine, those objects won't change with sliders. That's the case with tons of accessories.

But we can simply create this new set by clicking on the + here

image.png.4c7a5ef11caec657064e46de013e8ee4.png

then renaming it to uv_1, otherwise the game won't read it.

 

Also, if we do the data transfer step after creating the uv_1, there will be at least some of it there. However, the placement won't be correct 100%, and that's an issue if we want our mesh to deform correctly with sliders.

 

Vthena was honest and told us that the mesh was straight out of MD. I could tell because of how the triangles are not aligned into square-like shapes. As a curiosity, Pixar uses this sort of mesh in triangles, no retopology. However, they are animating a movie, so they can correct frame by frame any aberration. We're using it for videogames, and these are less forgiving with triangles and incorrect geometry at the joints.

 

So I wasn't surprised to find a rather chaotic uv_1. Still, it deforms really well in-game, so Vthena's method of data transfer must work well enough. The placement seems to be really accurate. But looking closely, there are stretched edges crossing side to side. I suspect something happened with the seams of the base mesh, or the data transfer mistook vertices from one side and the other, swapping them.

 

Spoiler

image.png.d536644ad3bff58b4ea3f2685214de54.png

image.png.e929da067a21e027eef30724315e139d.png

image.png.778441be9ee23690bb550ba99d5e9c33.png

But we're here to see the clothing, so I hid the UVs of the mannequin.

image.png.baf6e40990f1f45704f6d20aa60a18f7.png

Scaled by 0.5 in X, moved by 0.5 in X too to take a look at it directly over the texture

 Looks really good! However, we can see some vertex are out of place on the front side, where the peeking parts are held by the buttons and also the neckline. And where are the buttons?

image.png.731cb8a1f0e48231a3aab302731c1e94.png

To correct these few vertices, I zoomed in, then clicked on one. The orange lines tell me that this one should be on the left side- Hold on. the geometry doesn't match, there are way less vertices here. Let me check this one in-game, I checked the opened version only.

image.png.f0f505bf6546b0be49946cd2ecfcb196.png

Ah. Yep, there it is. All those missing vertices are making holes. ut oh well, most of us are here for the open version.
image.png.6d5316e1108f71d198b99bf76d74a55a.png

And that one doesn't get holes! Why? Because the uv_looks like this instead

image.png.69050d7888812dc29f3bd6a9ccf4af79.png

We see the stretched edges, yes, but that's not important for the game. What matters is the position of each vertex on this map. Missing vertex make holes, while those in the correct place, even if not split cleanly, will deform correctly! Wow, that's actually really interesting to know, we CAN be a bit messy this way without drawbacks.



I'm going to try to add the missing vertices to uv_1 on the closed version. But that will have to wait for tomorrow. I will also take a closer loot at V3, and look for the missing/obscured buttons on both versions.

I know it is a LOT of information. Please ask any question you may have about any step or concept.

  • 2 weeks later...
Posted

  

Alright, today I'm back and I'm going to try to make @Simite pumpkin into a game object.

 

There were 2156 faces on this object, and usually you want the most density around the main feature of the object, so the face. Instead, the top and bottom are very dense. I go them down to 1563 there (I can explain how I did it without retopology if anyone is interested). That roughly doubled once the Solidify modifier was applied. You need to apply it for baking, as the modifier only works while in Blender. If you export it without applying, the object would have no depth, and the interior would not show any texture in-game.

 

In TS4 the mesh only shows texture on the front face, the back is transparent, afaik. In any case, without the UV island in a different place over the Texture Map, the object would have the same color on both sides. There is no way for the pumpkin to be orange on the outside, and yellow on the inside without materializing the mesh first by applying the modifier, then moving the island to a different place that won't overlap the exterior.


I have unwrapped the UVs in a more game-ready manner, giving priority to the main features (face, top, exterior), then setting the island for the bulk of the interior. The vertical lines you see at the top are the cuts into the pumpkin to make the face. I have allowed them that much space be I haven't checke if any of them is upside down because I plan to first bake flat colors. Later, when I add details it will be clear on the mesh, and it will be just a matter of flipping the island (scale -1 in Y axis). Bottom and Top without the nub are also both sharing space, as they are orange. I might have to change this later if I want to add shading to the bottom.
 

Spoiler

 

 

image.png.c3aa86925b425b31bd81f29a6b735490.png

 

Simite did a lovely job coloring the three main parts of it, there are three materials in the file. So I can just proceed to baking the colors (Diffuse) into a texture map. Again, I'm choosing to do this with plain, flat colors first, no shadows from the render in Cycles. I'd like to bake the Ambient Occlusion (shadows that the object projects on itself) independently so I can later add it as a separate layer when editing the Diffuse Map.

From the tab, you should have an Image Editor on your left. Create a new Image, I recommend naming it acording to the map you're baking, so Diffuse this time. Set it for HQ (you can type *N to multiply Blender's default 1024 by N, so 1024*4, hit enter, it does the math for you and writes 4096 (HQ). And if it's a square map, you can click and drag across both Width and Height at once, it will fill what you type in both fields). I am unsure yet how to deal with Alpha in the Diffuse map, so I let it marked and just delete if there's any issue.

 

Next I had to set the colors to Nodes. I copied the hex codes to paste them on the Color field, because it defaults to white. After that, from the Shading Tab, look for Add, then Texture >Image texture. Don't connect it to the shader. Open the "Image Icon v" and select the Diffuse that was made on the step above. Click on the Principled BSDF box, then hold shift and click on the Texture box. It should look like below, the Shader outlined in orange (selected), the texture in white (active) I repeated this step for all three Materials, one for each color. Notice however that all three have the same Image Texture added. That is how we bake several colors/shaders in a single image.

 

Spoiler

image.png.b818e4c5b0eab7791bf34c7209fc5418.png

image.png.ad42f0f84d621dbd8942946fd2448820.png

(Diffuse Image should look like this before baking, or maybe no UVs showing, both options are okay.)

 

Then on the Property Editor, Render Properties, set it to Cycles. Here is where set up the quality of the image too. See the image below, there is a Sampling menu, and in it you can find Render. That's the one that affects the image we're baking. Here, we have a Samples field, and a number input. The higher this number is, less aberrations will appear in your image, but it will take a longer time. It depends on your computer's hardware too. With these settings and a decent computer (TS4 loads in under a minute), baking takes close to 5 minutes. It's sort of an overkill for what I'm doing (flat colors), half that gives a good result too, in this case. You're going to want to tweak it.

 

Next, scroll down to Bake. Set Bake Type to Diffuse, and select only Color in Contributions. One of the reasons I'm not dealing with shadows yet is that TS4 has a very peculiar way to translate light refraction (Specular). I want to use this model to experiment with it, so I want the Diffuse Map to have only basic information. (but I am realizing that I don't see the option for a Specular map in S4S for the object I'm cloning. Maybe it only works for CAS items, or this particular one doesn't have any. I'll have to see if that's standard later).
 

Spoiler

image.png.5362337fe7152bcbf9aeb27a7b2c710b.png

image.png.b99ee224510978a4c60298d683bdd2d5.png
image.png.5c6f188c1d5b4b6e1e5059137a965345.png

 

And here it is. Excellent base to start playing with.

 

Pumpkin_Practise.blend

Bonus: I was setting Blender to connect with Photoshop and tried to color the cuts:


 

Spoiler

image.png.f3ec3af8cdb3db590657e988305e669a.png

image.png.600fc8adbc37a27acc37195ada5d5d21.png

 

More on that soon, but I want to tinker with Specular and Normals next.

image.png

Posted (edited)

I want to make a glossary of terms too, so there's no confusion.

A 3D object has:

 

  • Mesh. This is the structure in three dimensions of your object.

 

Spoiler

image.png.6975fe0fc74f1903d2fc01bd37c39b5c.png

 

  • Vertices/edges/faces: the three components of each part that together form the geometry/mesh of the object. A vertex is the point where two edges cross, an edge is the line between two vertices, and a face is the sum of vertices and edges of a single sub-unit of the mesh.
    Looking at the statistics of this object, there are 2,961 vertices, 6141 edges, 3,176 faces, and those faces, if divided, sum 5,930 triangles.
     
    Spoiler

    image.png.a6d476e38f46fb3f8eb705d349b46b95.png


     
  • Topology: the mesh distribution along the surface of the object.

    A good game object will try to have mostly squares that align in rows and colums with each other. This helps textures to have as little stretching as possible, and to animatios to move cleanly, with almost no clipping (sharing the same space, looking to pass through each other).

    As reference, Marvelous Designer, the program some people use to create clothes, creates meshes only made by triangles, and no vertice is truly aligned. This is done to better reproduce fabric, that bends and flows in many directions in real life. But as we know, when in game, it makes weird edges and shadows.

    A clean topology also affects sliders in TS4. Because of how they work, with uv_1, aligning the object correctly is very important so the game knows how to stretch it. A fast, dense and triangular topology means more risk to bigger body settings to look wrong wearing the clothing.
     
  • UV: The 3D mesh in a 2D space. This is used to apply textures to the mesh, so it usually implies that no face overlaps another. UVs of an objects are a map that tells the game what section of a texture to show where in the object's surface.

    Baking uses UVs to know what section of the object to put where on the texture. All textures should use the same UV layout in TS4 (uv_0).

    You can cut the UVs in smaller segments to find the best way to "pack" the texture, giving more importance to features like faces than idk, knuckles. Each independent segment is called an island. Islands can be sewn together again too, and neither cutting or sewing affects the mesh.

    HOWEVER, if both faces are meant to have the same aspect in 3D (for example, vertical left and right halves of most animals), you can overlap them. This means that you cannot have them have any unique feature that isn't present on the other half/part. That's why in TS4, while the mesh is symmetrical, each side still has a UV space. This allows for things like tattoos, skin details, and also asymmetric clothing and accesories.

    This also means that if you have, say, a skirt with the same print in the front and back halves, you can overlap them to save space. A great use for this is to move the texture away from the body's skirt space, so you can slit or let it be hollow, so upskirt shots are possible. Same for any other body part, of course. Careful with where you put them, or they will show other object's textures superposed!

    In TS4, objects have TWO sets of UVs. uv_0 is used to read the textures and project it on the mesh, so the clothes have color (diffuse texture) and are affected by light (specular and normal texture). Then there's the uv_1, that maps the space an object occupies on top of the sim's own mesh. That way, when we deform the sim's mesh with sliders in-game, the clothing and accessories follow along, deformind the same way. Of course, that only happens if the object has the uv_1 correctly aligned.
     
  • Texture: a 2D image with the visual information for a mesh. There are four kinds of information: Color, "Volume", Light, and Transparency.

    Color is handled by the Diffuse texture. It uses the RGB channels.

    "Volume" is in quotations because it's actually a light and shadow illusion, and that's handled by the Normal texture. Most games I'm familiar with use a magenta to cyan scale, but TS4 uses grayscale. A normal map is sometimes called a Bump map.

    Light, as in the way it reflects off the object's surface, is handled by the Specular texture. This one is the most complex in TS4, imo. Each color channel, Red, Green, and Blue, and also the Alpha channel, is read in the game as a different sort of reflection. The best explanation I've found is this one:
    https://www.tumblr.com/needleworkreve/663045890723954688/these-are-the-results-of-my-in-depth-look-into-how

    But Light can also mean Emitted light. That is, yes, handled by the Emission texture of an object. Want to make something light up, like the pumpkin, or your sim's eyes, or an accessory? Then this is the texture you need to tweak. But keep in mind, this light only affect the object it's attached to. The surrounded objects will not reflect any light from it back, afaik. So it's like a glow in the dark effect.

    Transparency usually is handled by the Diffuse texture, this time in the Alpha channel. But because clothing share UV space with the sim's body and other objects like shoes or accessories, TS4 shaders don't work like that. Instead, you have to do some more work to make your item be transparent, calling the game's SimGlass Shader to the object. I haven't tried it yet so I cannot explain it with my words, so here's a link to a good tutorial: https://sims4studio.com/thread/16685/add-transparency-clothing-adding-new
    There seems to be a "SimGhost" shader too, that should be fun to play with.
     
  • Material, a combination of one or more Textures and/or values (for things like percentage of light or environment refraction) for how to make the object's surface look like. If we have a Diffuse (color), Specular (Gloss) and Normal (fake volume), all three combined in an object result in a Material. An object can have more than one Material while in Blender, assigned to different faces of the mesh. But to get those to show in-game, you need to bake the texture(s).

    A good example is to imagine a polished gold object, one that is actually glossy in-game, not just painted to appear glossy. The Gold Material is the combination of the Diffuse (yellow-orange color of gold) plus the Metallic value that is telling the shader to reflect back the surrounding objects. like a mirror. Most creators fake metallic/gloss effects because they're complex to make for the game. But they are not exactly impossible.


Okay, so that's a lot of words. But this explain why you may be having an object to look a certain way in Blender, and then you export it to the game and nothing looks the same. Blender has different shaders, but none are like the game's. Which leads me to the next definition.
 

  • Shader: the translator for how a 3D environment uses materials, objects and light to show them on a screen (not object!).

    Blender's Default Shader is the Principled BSDF Shader. It has lots of values to tweak and play with, most of them by a value from 0 to 1. However, none of those are "understood" by the game. That is why we "bake" our textures, so we export them in a format that TS4 can understand (.png, .dds, .jpeg). IF we had a TS4 Shader, then Blended would be able to bake all those Textures already game-ready. That shader doesn't exist afaik, so we have to bake, save, process them in an image editor, then import into the .package. Wait no, there IS ONE

    A great example for this discrepancy is the Specular Value. Blender can use just a 0 to 1 value for it in its shaders. But if you max it out, you'll notice that the shine is not that intense. That's because Roughness, Metallic and Clearcoat are also there, and all add information for the light/reflection on the object. The game's peculiar Specular Texture is that every color means one of those values (Specular, Roughness, Metallic, Clearcoat) in Blender's Principled BSDF shader.

    Pumpkin with a Principled BSDF shiny look and the values, as a visual example:

     
    Spoiler

    image.png.ee23404fd61f4dcd550bbf9eb0a4180e.png


    None of that shininess would show in game even if I baked with "Combined" option, or Glossy, or Roughness. That said, if I can bake Roughness and Glossy, then edit them in Photoshop to the right channels, something should turn up right? I have yet to try. I'll share what I learn.
     

Hold on, but there's a Shadow texture too!

Yes, right! I almost forgot. That's for the shadows that an object would cast on a sim. This one doesn't use the UV of the object only, but the whole sim. So if you make, for example, a necklace, it would cast some shadow on a sim neck and chest. Or clothes cast shadows on necks, wrists, legs and any other are that may be beyond the clothing itself. As a rule of thumb, the closer it is to skin, the darker but smaller it is (tight clothing), while clothing being further away has a lighter but bigger shadow area.

So in a way, the Ambient Occlusion. But we would want to bake them for the cc AND the sim mesh, while usually AO is only baked for the object we're making (cc). This one is pretty simple, but a lot of people don't include it. It doesn't matter for some cc, but other times it makes it look more "fake". Our brains expect a darker look there that isn't. For a high quality, polished look, remembering to create a Shadow Texture is a great step, imo.

Edited by Mimi-e

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...