View Full Version : Confused on creating hair mesh package
Phaenoh
25th Sep 2007, 06:58 PM
Im interesting in making a hair mesh for toddler girls, but I dont want to make it for all the other ages. I'm new to both meshing and hair, so I don't know if that will work. If a toddler with my new hair grows up, will they be bald rest of their life, or will they be auto-assigned a maxis hair? Past that, are there any spiffy tricks that aren't in the hair meshing tutorials that I should know about? Thanks again guys!
HystericalParoxysm
25th Sep 2007, 07:22 PM
They'll be assigned a random hair from the same bin - usually Maxis, usually the short bob.
Tricks not covered in the tutorials? The Anim button on the keyframer and the ability to rotate joints using that Anim mode to see how your meshes animate without going in-game. Make sure the Keyframer is visible (Window - Keyframer), click Anim. Make sure your skeleton is visible, joint size set to 0.01 in your options. Select mode set to joint. Select a joint in the skeleton (for hair, probably the head). Go into Anim mode, then Rotate - make sure you're rotating around the Origin. Examine how your mesh rotates that way. Unclick Anim and your mesh snaps back to normal, ready to be edited. Repeat until insane and/or mesh is fixed. ;)
Phaenoh
25th Sep 2007, 10:48 PM
Snap, didn't even think about animating it. I hope there a tutorial for that too?
WesHowe
26th Sep 2007, 02:02 AM
What H-P is describing is using the built in animation part of MilkShape for reviewing a sort of simulation how your hair will look live in the game. If it cannot be moved in MilkShape without problems, it will not be able to be moved in the game without the same problems appearing.
H-P is the first person I am aware of to suggest using a "temporary animation" for the purposes of quality checking a hair mesh.
Transferring the actual "temporary animation" to the game is a far more complex topic. I do not know anyone that has yet actually created a new hair animation. So far, all the work on hair has been in properly assigning the mesh parts to the five "_hair" bones so that the custom hair meshes are animated by the default game hair animations. These are the animations that make the ends of the hair strands push outwards when the sim spins around, among others.
Echo describes in this message some information about how to get MilkShape animation started. While this is part of a tutorial on object animation, the essentials are the same except for the bone names:
http://www.modthesims2.com/showthread.php?p=1707091#post1707091
This thread also has some discussion of importing body meshes (and a hair mesh is a body mesh with hair and no body) and animating them in MilkShape:
http://www.modthesims2.com/member/showthread.php?p=1548640#post1548640
You need not try the actual importer plugin linked in the first thread, because it is built-in on the later (4.08 or 4.09) versions of the UniMesh plugins.
<* Wes *>
Phaenoh
26th Sep 2007, 02:52 AM
Yikes, this is looking like a scarier project the further in I go...though, when is that not the case? Ok, I will give those a look.
...Do I need to worry too much about the animation? I thought that as long as I correctly assigned bones everything would work just like a maxis hair cut. The stuff you (wes_h) were talking about creating a new custom hair animation seems a bit over my head. Do I need to worry too much about what you said?
WesHowe
26th Sep 2007, 03:43 AM
No. You need not make rela, permanent animations, or use the AnimExporter, in order to test the way H-P describes.
If you assign the bones properly, the game will animate the hair the same way Maxis hair is animated. Checking this in a manner faster than export, load into SimPE, save, copy to downloads and start the game is what she was trying to clue you in on.
This is actually pretty easy, and fast, once you learn which buttons on MilkShape have to be clicked. You would select the head joint (or more on a longer hairstyle) in the joints panel, click on 'rotate' in the model panel (and use 'local' mode) and then click on the big "ANIM" button in the lower right corner. You can now click in a window and drag the mouse to make the hair spin around.
It is hard to explain the way it will spin, but each certain view, dragging left and right or up and down will always rotate the hair in the same manner. If you have made a good backup, you can experiment until you see the way it works.
And as H-P said, when you click on the ANIM button again, your temporary moves disappear, and the default pose is restored.
<* Wes *>
HystericalParoxysm
26th Sep 2007, 06:35 AM
I'm the first person to suggest that? Seriously? Sheesh, I thought other people were already using it and I was just slow to discover it.
I used it in doing my Adrasteia hair, to get all the layers animating right for head tilts and turns. I dunno if it'd be at all useful if you're assigning to the actual bouncy hair animation bones but it's wonderful for smooth transitions if you're doing something that goes down toward the shoulders. Made it very easy to see what was pulling wrong, what vertices were spiking out, etc., without having to go into the game for every single little change (and then trying to find what it was in Milkshape vs the game - very hard sometimes with many layers of stuff happening). I just wish I could set up a macro to click the buttons for me - I probably went through that sequence of four or five clicks at least a thousand times in doing that stinkin' hair.
Phaenoh
26th Sep 2007, 06:28 PM
That raises another question, the hair I want to make is short and full of curls. How do I make sure that animates with bounce and not like long hair does?
Ok, back track a bit. Why is creating the mesh package so darn confusing? I changed my mind and would like to create this hairstyle for all ages, but I'm getting tripped up at the simpe steps of making a package. I'm going back and forth between the hair tutorials and the clothes tutorials, but in my opinion they seem to skip a few things. The clothes ones goes over the basics and mostly holds your hand through it, but then the hair ones are all like, we think you know what you are doing, if you don't go to the clothes and be coddled. What about the inbetweeners, who have done it once or twice, confident enough to step up from the clothings, but don't understand how to put together a complicated package. Do I make one package for each age, that doesn't seem to make sense if I want them all to link together genetically in the end. How/when do I fix the integrity of it, do I do them as separate packages and then put them all together in the end, or what? I guess what I'm trying to convey is that the learning curve is a bit step for these tutorials. /rant over, though still frustrated.
Echo
27th Sep 2007, 12:38 AM
Which tutorials have you done?
http://www.sims2wiki.info/wiki.php?title=Tutorials:Body_Shop_Meshing_Hair_Tutorials
The second and third posts in this thread cover different age groups:
http://www.modthesims2.com/showthread.php?t=139819
I'm thinking this thread would be better off in Bodyshop meshing. Whooshing now.
Phaenoh
27th Sep 2007, 12:52 AM
Thanks for the whoosh. Yes, I've been reading all of those. I'm just confused at the making the package stages. I understand how to find all the parts I need and add them, but im stuck at which ones i need to go get exactly, not like cres and gmdc, but like which hair style pieces to grab. I really don't understand the linking processes. Linking my new mesh from milkshape to be the one bodyshop uses and also linking the ages together.
RenegadeSims
27th Sep 2007, 07:58 AM
HP - How on earth did you get the hair to bend so smoothly when the Sim turns their heads? Like which bones did you assign the hair around those parts to? It looks really good, I think you did an amazing job :)
Phaenoh - What do you mean by "which hair style pieces to grab"? I assume you've exported & imported your template hair from Bodyshop?
Once you create your mesh package, you just drop your fixed/modified cres & shape into the .package file created by the export/import of your hair in Bodyshop (found in SavedSims folder), then follow the steps in the tutorial from there. I'm not sure if I just made that more confusing lol.
It is when you drop in your modifiedcres and modifiedshpe and then use the Package button to drop them in the appropriate 3DIR that links them.
Don't worry if you link the mesh to all ages of your recolour - you can always delete them after.
Also, if your toddler hair is short, you don't NEED to animate them to bounce and whatnot. Even if it's long, maxis-style animations are not necessary. I'd worry more about making sure hair is assigned appropriately so that hair doesn't end up stabbing the sim in odd places lol.
I really hope I didn't make things more confusing. I tend to try and simplify things so that they're easier for me to remember later on. It's also been a while since I've looked at the basic hair/body mesh tutorial.
Good luck :)
Phaenoh
27th Sep 2007, 05:26 PM
I've fiddled around with it a bit more, sleep on it and such. Some things are just clearer in the morning. I think I'll be able to pull it off. Thanks again guys, and sorry for that bit of frustration showing through, very unprofessional of me. ;-)
HystericalParoxysm
27th Sep 2007, 06:26 PM
RenegadeSims - It's a very smooth transition from spine2 to spine1 (or the other way around, whichever is higher up on the spine, I forget at the moment) straight to head - the only places I assigned to neck were the parts on the sides right up against the neck. There are no assignments to any of the "hair animation bones" for bouncyness in the breeze as curly hair tends to be pretty stiff anyway. You're welcome to open my GMDCs to prod at them in Milkshape and see what it looks like... they look awfully pretty with Milkshape's showing the vertex weights in lovely colours enabled. :) I think the main secret, especially at the back of the neck, was not being afraid to make them transition -really- smoothly, i.e. continuing spine transitions up the hair at the back and sides of the head quite a bit further than one might expect. If I recall the spine assignments only truly stop about a hand's width from the crown of the head.
Phaenoh - *meshy hugs* It's frustrating sometimes. Stepping away and coming back to it after a break or sleep is usually pretty helpful. Not for the faint of heart or the lacking of patience, but you'll get it. :)
RenegadeSims
27th Sep 2007, 07:22 PM
HP - Thank you :) I only know how to assign spine1, spine2, and hair bones through experimentation and looking at other meshes. Though I think not assigning to the _hair bones makes the hair actually stay where it's supposed to: i.e, if the hair is supposed to rest against the chest, it will help if no _hair bones are assigned to it, otherwise it is more likely to clip. At least, that's been the case for me.
Although, spending a LOT of time creating a smooth transition would probably get that effect. I admire that you did that :) - it is VERRRY tedious work!
Milkshape highlights vertex weights?! This is news to me, unless there was another Milkshape update recently. I currently use 1.8.0.
Phaenoh - HP is right, it's very frustrating sometimes and taking a break definitely helps. If you keep your patience (you don't need to keep your sanity :P) you'll eventually work it all out.
By the way, showing frustration is not bad at all: you need to be able to vent, and this is the Meshing help forum! It's okay to show a bit of frustration, pound the walls in frustration, etc lol, most people here have been at that state! I'm pretty sure this forum here is for help & support, so definitely come here when you need it :) Again, good luck!
Phaenoh
27th Sep 2007, 07:42 PM
I lost my sanity a long time ago, design colleges tend to do that to you. I find life is alot better without it anyways. You can relax, breathe, pause time, and actually get your work done that way!
HystericalParoxysm
27th Sep 2007, 08:12 PM
By the way, we do have an IRC chat about Sims 2 creation of all kinds - http://chat.modthesims2.com ... I'm in there most of the time and can be prodded (by way of saying whatever name I'm under at the moment - usually this one, HP|Something or Aychpee) to yowl at about meshing issues or to show pretty pictures or just vent or whatever.
Renegade - 1.8.1b is what I'm using, but it's been in the last few versions... Joints tab, draw vertices with bone colours. Do it with a body mesh first. Pretty colours. Ooooooh.
I honestly haven't done much with bouncy animation. I haven't done meshes that I feel it's really necessary or would add enough to the mesh that I should bother. And it does simplify things a lot, yeah, you know where something is gonna be, pretty much. Assign it to the actual hair animation bones and it starts flying around when the sim turns fast enough. I think it adds a lot when done right - Nouk's stuff is a great example of it done well.... and looks absolutely terrible when done wrong (you know what I'm talking about here... *eyepatchy wink*). But I'd rather see a mesh without it than have it done wrong, personally. :)
Phaenoh
27th Sep 2007, 08:43 PM
Had no idea about the livechat.... learn something new everyday. Is it interesting?
Echo
28th Sep 2007, 12:26 AM
Had no idea about the livechat.... learn something new everyday. Is it interesting?It's awesome. :)
Phaenoh
29th Sep 2007, 11:00 PM
Ok, so I'm picking this project up again, and I'm able to articulate my original frustration in a constructive fashion. When I'm putting together the hair package, do I put the modified cres, gmdc, etc into my bodyshop package for all the ages I want to change and then Fix Integrity, or make four new packages, each with a different age in them, fix integrity, and then add them into the bodyshop file? I don't really understand what fixing integrity does, so I can't answer this question myself.
Bribe: I'll save a brownie for anyone who answers before they come out of the oven (50 mins, go)
Dr Pixel
30th Sep 2007, 12:03 AM
What I do is make each age group one at a time, first as it's own separate MESH .package. This is necessary, because "fix integrety" is meant to assign a uniquie ID number to all your mesh parts - similar to the GUID number that object .pacakges use - but it will assign the same id number to everything in the .package so it is necessary to first make each as it's own separate .packge, do the Fix Integrety on it, and then the linking step.
I always do just the adult one (which is for adults, young adults, and elders) first and do all the actual editing and experimenting to that one.
Once I have that working, textured the way I want, and thoroughly game-tested, I next make the teen's MESH .package and convert the adult mesh to it.
Again I test it in-game, and make any needed changes.
Repeat for the child's, and finally the toddler's.
I find, at least with longer hair, the Toddler is always the hardest to get animated right. Because unlike the other ages, toddlers spend a lot of time crawling on the floor, with their head and neck bent back at an extreme angle. But later, when they can walk, they will also stand up with their head in a normal position. So it can be tricky to get it to look right in all those positions.
Once I have all four finished and tested, I then combine all the separate MESH .packages into one MESH .package. This won't cause any problems now, as long as you do NOT use fix integrety again.
==================================================
HP, for your mesh animation testing, you could actually just do it once and export it as if it were going to be an actual in-game animation. Just do all the testing movements you want, setting them as keyframes like in the animation tutorials. Then export it someplace safe. The animation exporter exports only the bone animations, not the mesh, so your animation isn't "married" to a particular mesh at all.
Whenever you want to test a mesh, just import the same animation and have it play while you spin the view around in the 3d window to see how things are working. You can also single-step through the animation, as if it were a set of still poses.
Phaenoh
30th Sep 2007, 12:34 AM
Where do you want me to send you your brownie?
Thanks so much for answering my question so quickly! Your explanation cleared a lot of things up for me. Now, back to following your tutorial...
Later: SWEET ACTION!!! I've finally got my mesh into bodyshop!!!! Granted it looks like crap, but its actually working enough for me to be know that it looks like crap! HURRAY!! Is there a "Happy-Mesh-Working-Dance" that I could be doing right now? Cuz I'm feelin' it.
...now to make it not look bad and figure out how to give it a proper UV map, i do hate those things, but they are always worth it in the end. Any ideas on how to map a spiral? Or better yet, 38 identical spirals?
Even Later: I kinda feel bad that I'm asking so many questions, I don't want to bug you guys too much, but I get one thing solved and three more questions pop up.
Three more questions: 1) How important is it that my starting mesh have the same number of groups as the ones I import? So far, I've just been combining the existing groups to get back down to the right number (I'm making curly hair for toddlers from the kids curly pigtails and the adult curlsup bun-ish hair style) Currently my toddler base just has the hair and hair_alpha. I'm starting to think having more groups to work with will make uv mapping it alot easier. Currently I've got no idea how to pull it off. 2) What are the comments for, and how important are they? I've pretty much been disregarding them so far, and in bodyshop, my mesh looks about as what I thought it should look. 3) This style is going to require some layers to be transparent in some places, so I don't get a silly cylinder looking curl. I'm understanding that this is done by having 2 groups identical but inside out of each other. Is this the only way to do it, so going back to my first question, I'm going to need a new base for it right? Thanks again. I'll I can promise is that once I learn how to do something, I never have trouble with it again, so all your help will not have to be repeated for me atleast.
RenegadeSims
30th Sep 2007, 07:49 AM
Comments are pretty important, I'd say. From what I've been able to figure out, the names need to match the group name. Set the opacity to what it should be, and ideally, you'd want NumSkinWgts set to 3. The "hair" group generally always has an opacity of -1. I don't think the "TangentArray" is overly important, but I think it does enable things like bumpmapping and whatnot.
Here's an example of what the comments box looks like for my hairs:
ModelName: hair
Opacity: -1
HasTangentArray:
NumSkinWgts: 3
And questions are good. I wish there were more detailed hair-specific tutorials out there, unless there are and I just can't find them lol
HystericalParoxysm
30th Sep 2007, 08:31 AM
Dr Pixel - An interesting idea if I was doing the same animation over and over... unfortunately what I would do each time, animation-wise, was slightly different - tilt the sim's head forward, to the side, back, etc., and watch what happens with certain vertices. I just need to find a macro program that will click stuff for me so I don't have to click the same four buttons a thousand times per mesh. ;)
Phaenoh - Regarding that "how do you map a spiral" - take a look at the curls on the curlsup hair. They're a cylinder mapped like a soup can. Bit of a pain in the ass if you're doing a brand new fresh texture, to texture across the seam properly, but you could probably trace the original textures and do okay that way.
Regarding the number of groups... that's the very FIRST thing you should look for in a hair. Before you even start meshing, you'll need to draw yourself out a little plan, trying to predict how the layering will go, how things overlap, etc. - this is often the hardest part to get right for me, and if you do it wrong you can get transparency issues. If you only have those two parts then you don't have enough to do what you need - you'll need at least three parts for inner/outer on your curls, and then your non-transparent alphas-to-skin hair group. More is better - Nouk made a totally kickass package with I think up to 15 groups for all ages (and you don't have to use all the groups - they're just there if you need them). Might send her a PM and ask if you can clone from it (she'll likely be using it on any of her new hairs) - I'm sure she'll say yes.
Something that may work for you, I'm not sure... you -might- be able to get away with just the three groups though. If you look at my Cherub hair, it's just got three groups - hair, and two alphas, which are the front and back of each curl. For some reason, despite being jumbled and overlapping all over the head, the only transparency issues that hair gets is when you're viewing, say, a wallpaper behind it - it gets edges where it overlaps the background, but not itself. Depending on how long and volumeful your hair is gonna be that may work for you. I have no idea why it works at all - it doesn't seem like it should... the layering stuff is... really annoying.
And yes, the comments are very important. You can usually just copy the comments from the original groups and be fine - just make sure the NumSkinWeights is always set to 3, as Renegade said (otherwise if you weight a vertex to three bones, it'll strip off the third assignment and you'll end up with inexplicably transparent, underweight parts).
And yes, you're correct on the nested cylinder concept. Normally when I build a hair mesh I do all the outside parts, piece by piece, and then when those are ready I select each group in turn, duplicate it, scale by .999, reverse vertex order to flip it, then align normals. That gives you a perfect inner layer, and you don't have to worry about getting everything aligned properly with your inner layers until the very end. With certain strange shapes you may end up with your inner layer glittering or flashing black through your outer layer in Milkshape - this is perfectly fine.
Asking questions is GOOD! It's how you learn! Don't be afraid to bombard us with queries - eventually you'll be knowledgeable enough to answer some questions from baby meshers yourself. Pay it forward and all is well. ;)
Renegade - I thought about writing a more advanced "mesh parts from scratch" tutorial when I was doing the Adrasteia mesh, but there's just so many different things that can go wrong, and it's SUCH a long process, it's really hard to do without just telling people how to make that one thing. At least in my experience, hair meshing is equal parts experimentation and frustration, with a little sprinkle of asking questions when you get stuck. ;)
RenegadeSims
30th Sep 2007, 09:28 AM
True, though that would have been an awesome tutorial. I've been wanting to learn how to mesh from scratch, since most of what I do is just fixing or pulling around Maxis hair. If you were up for doing a "mesh parts from scratch" tutorial, maybe do something basic, but not too basic? Maybe a short-ish straight hair or something like that - nothing too complex, but something that would create a stronger ground for those wanting to learn how to make a hair mesh from scratch. I guess something that would cover making shapes, etc. I'm sure you know what I mean :) I'm sure writing a tutorial like that would take a really long time (only because it would have to be very detailed, probably) and the questions that would naturally spawn after...hm. Well, if you're still thinking about doing it, then I wish you the best of luck.
Personally, I've followed some of the clothing mesh tutorials, but I get to a point where it all just goes over my head (sometimes I need things to be explained to me as if I'm 3 lol), and I also for some reason have a hard time relating the clothing mesh tutorials with hair stuff.
Also, I don't think I've found a comprehensive guide for bone assignments (for hair), though that can also be figured out by looking at others' meshes in Milkshape.
But I'd say Phaenoh seems to be doing quite well so far :) Just keep at it, and you'll finish it well. I'll be looking forward to seeing the result!
HystericalParoxysm
30th Sep 2007, 09:39 AM
I may do a little mock-tutorial if I find the time, showing how to create fresh new parts and put them in place. I don't have much interest in making hair lately myself but showing how to make a couple new parts and squish 'em into place wouldn't be too difficult, I think.
Honestly all I ever do is use subdivided planes (or, in the case of the Cherub, simple half-spheres and subdivided planes), kind of plotting in my head how many bends I'll need before I make them to see how many subdivisions I need before making the piece. Once it's made, flat and basic, it has a really basic map that covers the whole texture, which is fine... And then I just spend a lot of time shifting around individual vertices and aligning normals till I have something smooth and nice in there, the shape that I want, and then I apply Tig's blue grid for UV mapping and then adjust each piece until it has as close to the grid in undistorted squares as I can get. Bone assignments come last. :)
When it comes to the bone assignments... yes, most of that I have figured out by looking at existing meshes, and also just applying basic assignments based on a Maxis body mesh underneath, duplicating the assignments from the body in my hair mesh - if there's a vertex in the body on the shoulderblade and there's a cluster of several vertices in the hair over that vertex that are close enough, they'll all get the same assignments as the body vertex... Then I'll just continue duplicating body assignments on clusters of hair vertices till I have something really basic on the hair, and then start doing the Anim thing and tweaking from there. This is especially helpful in things like overlaps on chest and shoulderblades, where the r_clavicle and l_clavicle assignments are really helpful in preventing clipping around the edges.
Phaenoh
30th Sep 2007, 03:59 PM
So from what I'm seeing here, I need to start over. I need to find a toddler hair that has at least 3 groups, im thinking that ugly bobcut might have enough. Then I need to copy down somewhere the comments for each of the groups. Then i can start meshing it again, (third times the charm?) Each of these groups needs to get UV mapped at this stage, make it all look pretty somehow. Fix all the bone assignments (should I leave them what they were from the old meshes I took them from, or just make them all head and base couple also neck?) Then stick it back into my package and pray like mad it looks decent in bodyshop. That the correct process?
HystericalParoxysm
30th Sep 2007, 04:33 PM
You can probably keep anything you've meshed thus far, assuming you haven't combined parts that you can't pull apart that need to be in separate groups - you just need to start a new mesh package/recolour with the right number of groups, and make what you have thus far fit its group names/order.
Make each piece and as you make each piece, give it a basic uv map. You don't have to give it a perfect UV map yet unless you're going to be duplicating that piece over and over and using repeating textures, in which case you should go ahead and get the map pretty much done before you duplicate, so all your pieces of that type are the same.
Then, once you have everything in place, adjust the maps for anything that isn't final on mapping.
Then, do -head- assignments. 100% head for everything. That's temporary, for Body Shop testing of everything showing up properly, transparency issues, mapping, and texturing. Once everything looks perfect and beautiful and stuff in Body Shop -then- you worry about doing something more complicated than head assignments - fix the neck gap, start adding bouncy animation if desired.
Phaenoh
30th Sep 2007, 05:18 PM
lol, like I can figure out anything more complicated that just assigning it all to the head. There don't seem to be any tutorials explaining that. I'm nowhere without my precious tutorials.
I think I'll just start the mesh over, I've got alot of repeated parts, so its easy to remake, and anything that makes uv mapping easier it is worth its weight in gold.
HystericalParoxysm
30th Sep 2007, 05:33 PM
Well, the neck gap thing is covered in Dr Pixel's tutorial, so that's okay. :)
The other stuff with hair assignments... I think really comes more with study and experimentation than tutorials. Looking at stuff that kinda works like what you want, and checking out what it's assigned to. Using underlying assignments on the body to tack it down in the right places if it's going down that far. Using nice smooth transitions from one bone to another as you move away from one toward another in your assignments so things don't crunch... all helpful. :)
Phaenoh
30th Sep 2007, 05:48 PM
The hairstyle im working on isn't any lower than the chin, does all the smooth transitioning stuff matter for this one?
What is the importance on not having the layers poke through each other?
...heh, maybe when I'm done I'll write up a Hair Beginners FAQ for you guys. Fill that gap that caused me so much frustration, so others don't have the same troubles...
RenegadeSims
30th Sep 2007, 09:12 PM
If the layers poke through each other, I'm pretty sure that in most cases, you'll be able to see this once you have the hair textures done. In some colours, poking through might be more visible than with other colours.
If the hairstyle doesn't fall below the chin, I'm pretty sure you could get away with just assigning it all to the head (aside from the bottom 5 scalp verticies, which need to be 50/50 head/neck).
What I find helpful is to save multiple copies of the project I'm working on so editing becomes much easier. What you could do is save your full mesh (when it's all assigned to the head) as a .ms3D file (I assume you use Milkshape), export it into the game, and test it out on a toddler. If you find that the hair doesn't look good when the toddler is crawling, you might want to go back in Milkshape and try and fix up the part that causes a problem. Save that in a different .ms3D file, export, test in game if necessary.
You can definitely figure out bone assignments, if you're at the point where you can make a mesh from scratch :)
Study some meshes you have in your game already, just pick a style that may or may not be close to what you're looking for, and click on some vertices (I generally select one vertice at a time) and use Bone Tool to see what bones they are assigned to. The parts I've seen hair being assigned to are the "head" bones, "neck", "spine1", "spine2" and the l_ and r_ clavicles. And for animation you have l_hair, r_hair, f_hair, b_hair, and c_hair. I don't often see "c_hair" used in custom meshes, I believe it's for animating hair at the centre or top of the head.
If you are studying meshes for bone assignments, I would recommend NOT looking at PeggySims or RoseSims custom meshes.
As for hair faqs/tutorials - I think any type of beginner tutorial that is hair-specific would be good for beginners. Not necessarily fresh beginners, because the clothing and beginner hair tutorial by Dr. Pixel are there for that. But something for after you've finished that tutorial, how to make a hair from scratch when you're a clueless beginner or something lol! I might be slower than most, though, but I think it would be helpful to have something like that.
Phaenoh
30th Sep 2007, 10:49 PM
I don't really think I am making this mesh 'from scratch' I'm just taking other maxis meshes and adding and subtracting and duplicating. Good idea to look at other hair meshes for bone assignments, I know which one exactly too.
As for tutorials, I think I was just going to right up a quick summary of all the questions I've been asking here. Since I'm really good at following tutorials and still couldn't figure the answers out, that generally means the information is less than readily available.
Still didn't get an answer about layers poking through, is this 'bad' or just looks bad?
Dr Pixel
30th Sep 2007, 10:58 PM
If the different layers "poke" through each other it won't hurt anything (as in crash the game or cause other problems) but it may look bad.
In other words, if it looks OK don't worry about it.
Here is a link to a post I made showing hair assignments I made for a shoulder-length hair mesh. It may help. At least it has a picture, which is easier than trying to explain in words ;)
http://www.modthesims2.com/showthread.php?p=1000219#post1000219
RenegadeSims
30th Sep 2007, 11:28 PM
Actually, that's a very good post. I have noticed that if you happen to find the right post, sifting through threads, you'll find some really good informatioon for hair that's not covered in tutorials. Unfortunately, it's not very easy to locate posts like this, which is why a comprehensive collection of hair-specific posts/tutorials/faqs might be good.
Thanks, Dr. Pixel :)
Phaenoh
4th Oct 2007, 10:11 PM
Ok, so I'm back to having a working package, I subbed out the toddler hair for one that had more groups, I fixed some random issue the kids hair was having and I even binned it blonde. (Im stalling on going and remaking the mesh)
I'm trying to organize myself a bit here. I've got too many files, and I don't know which ones are necessary. In the end I want as few files as possible. I have a file in my SavedSims folder, and a couple in my downloads folder. Do I need a separate file for my recolors and then one that is just the mesh, or can I combine all 4 colors, all ages, and the meshes into one file? What is the standard for new hair meshes?
Later: Stalling forever doesn't work. I'm working on the mesh again. I just noticed that I think the child curls cylinders that I'm working from aren't double sided, yet the alpha still can cut them into ringlets...I thought to make parts of the mesh disappear they had to have two identical insideout groups. Any thoughts?
Even Later: Ok, now I have a problem again. I'm DARN sure I started over with a tot mesh that had 3 groups. After editing my mesh back down to just three groups, I loaded it into bodyshop. When I went to go make a recolor of it the exported projects file only had 2 groups. After editing it (to make sure) it really only has 2 groups. My method of starting over was putting together the new tot mesh package, all 4 pieces, fix integrty, and then put my modified cres and shape into my old SavedSim package file. Was this not good enough? Starting to get a bit frustrated again, need someone to talk to.
Dr Pixel
5th Oct 2007, 12:15 AM
I'm trying to organize myself a bit here. I've got too many files, and I don't know which ones are necessary. In the end I want as few files as possible. I have a file in my SavedSims folder, and a couple in my downloads folder. Do I need a separate file for my recolors and then one that is just the mesh, or can I combine all 4 colors, all ages, and the meshes into one file? What is the standard for new hair meshes?
Although it would be possible to combine everything into one .package it isn't a good idea. The problem would be that BodyShop and the game allow you to delete individual hair colors - but if everything is in one .package deleting a single color would make everything disappear. A combined .package with everything in it would also be a huge file. It's best to combine all the mesh files for all ages into one mesh .package, but leave each hair color in it's own .package.
Later: Stalling forever doesn't work. I'm working on the mesh again. I just noticed that I think the child curls cylinders that I'm working from aren't double sided, yet the alpha still can cut them into ringlets...I thought to make parts of the mesh disappear they had to have two identical insideout groups. Any thoughts?
I have noticed the same thing with that mesh. I know why they were able to get away with it on this mesh, but I don't know how to explain it very well.
The best I can do is say that you can never look through part of the curls group and see more of the same group.
If that doesn't make sense, just remember that this mesh is the exception - usually if you try doing it this way you will wind up with strange transparency glitches.
Phaenoh
5th Oct 2007, 12:47 AM
...great, my first attempt at meshing hair, and I pick one that has exceptions to the rules. Peachy keen. Now what?!?
Ok, I understand what to do about the packages now. That clears things up.
Still not sure why my tot hair is acting like it only has two groups, is that information stored in the file that Bodyshop made me originally, and so meaning, I have to redo that part all over?
Thanks for responding Dr. Pixel, I was almost about to lose it again.
Later: HOT D4MN!!! I quit working on the toddler one since it was bugging me so much and i have no idea what to do to fix it. I went on to the child version and so far, it looks pretty sweet! The repeated curls are still ringlet-ing like the original mesh, so even if I don't understand how it worked, I can atleast duplicate it if I'm careful enough. I even have a halfway decent UV map for it too! :: does a little happy mesh dance ::
Much much later: I seriously need to go to bed, but the boyfriend is still having too much fun with his brandnew Wii, I'll keep working till he gives up. So far I've got a cute little girls hair cut, and its even mildly animated. I looked at what the ringlets were on the maxis mesh and just duplicated them for all mine. Then I tried it in the game.... looked kinda silly, my curls seemed to pivot on the top of the head like a seesaw or a swing. I'm gonna go try and change some more values. It would be helpful to know what all the b_hair, c_hair and f_hair things mean, currently I'm using the c_hair, and i looked at another nice swooshey hair style and it had b and f in it, have these been deciphered somewhere?
Dr Pixel
5th Oct 2007, 09:48 AM
If you used c_hair, yes it will pivot from the top of the head.
c_hair = center
b_hair = back
f_hair = front
l_hair = left
r_hair = right
The BodyShop color .package determines how many groups your mesh will be able to use and what the mesh group names will be - no you don't have to start all over. This post explains how to add more hair groups to a color .package: http://www.modthesims2.com/showthread.php?goto=newpost&t=213184
Or you could make up a new BodyShop color .package starting with a hairstyle that does have enough groups for all ages. There is a list of some of them here: http://www.modthesims2.com/showthread.php?t=149677
Then link that to your mesh .packages. It will look all messed up at first since all the textures and alphas will be wrong, but that is easily fixed by exporting it in BodyShop as a new project and then replacing all the textures and alphas with your new ones.
HystericalParoxysm
5th Oct 2007, 10:50 AM
I should poke Nouk and see if I can get her to release her 15-groups-for-all-ages package as a simple cloneable thingie like she'd given me to use. That would essentially remove the need for any guesswork when it comes to what to clone from, or having to add groups.
Phaenoh
5th Oct 2007, 06:03 PM
You can poke Nouk all you'd like, but I'm going to be stubborn and not use hers. I like to do everything myself, I learn more that way. After I've figured things out, then there is no point to doing busy work, but in the beginning I see more benefit to pulling my own hair out getting this hair to work.
As for the animations, well, I think I need to tighten up the screws on the head assignments for the top, the rest looked okay. As for groups, what happens if I get a starting package that has too many? Can I just delete them, or will that not work/still have too many layers for bodyshop?
HystericalParoxysm
5th Oct 2007, 06:11 PM
Hehe, suit yourself. I've always cloned from whoever's meshes I can when I can - most of my early ones are cloned from melodie9's, cos adding groups is a bit of a pain.
If you have extra groups you don't need, what I always do is make a single plane out of three points, shrink it to a single point (snap together) and hide it inside the head with 100% head assignments for any missing groups.
Phaenoh
5th Oct 2007, 06:22 PM
Thanks for the tip, ... though, can't it be done properly through simpe? Like reverse of adding groups?
HystericalParoxysm
5th Oct 2007, 06:30 PM
I'm sure it can be - remove the textures and material definitions and all the other links... but it's really not necessary to do at all. Just use the same textures for those groups in the recolour and it should share textures and stuff. I don't think the extra unused groups add any appreciable strain or anything.
Phaenoh
5th Oct 2007, 06:44 PM
Just doesn't seem as tidy, thats all.
I'm about to go test out my third animations attempt, yippie skippy? Marks attempt no. 15 since I started over the third time, I'm really hoping this is normal.
WesHowe
5th Oct 2007, 06:58 PM
I am not a hair mesher, but other things I have done usually require dozens of edit/export/test cycles. Perseverance and perspiration are more valuable than genius (although a little talent helps).
<* Wes *>
Phaenoh
5th Oct 2007, 09:09 PM
The Good:
I have the child one working perfectly, animated and everything.
Teen version, added 3 groups to it, and seems to be working fine so far.
The Bad:
Adult version, didn't add any groups to it, though they weren't the original names. That got my bodyshop to crash, I'm going to try leaving the original names intact.
The Ugly:
Toddler version, added 1 group to it, and I have NO IDEA what is going on with it. When I spin the model around, the mesh doesn't rotate correctly, I don't really know how to describe it cuz I don't know whats going on with it.
WesHowe
5th Oct 2007, 09:20 PM
Almost all body meshes you would import have three skin weights.
But, some hair meshes have only two, and maybe some have but one.
There is a group comment something like "NumSkinWeights: 3".
If it isn't three, make it so. On all groups.
Your symptoms also sound like maybe some vertices are assigned to nothing or to the wrong bone. That is the primary reason that something does not move along with the rest of the body. Your assignments to the "hair" bones should probably not exceed 10 or 20 percent, at least in most meshes.
<* Wes *>
Phaenoh
5th Oct 2007, 09:35 PM
I figured out what caused bodyshop to crash, I had accidently replaced the GMND instead of the GMDC,... oops. So I fixed that and now it is behaving a bit like the toddler hair, all the curls on the bottom are acting like they should, but the curls on top (separate groups) are spinning weirdly. I'll go check the bone assignments next, thanks wes!
After a bit more looking at it in bodyshop, I've noticed that it is cutting though my other hair groups, it only hides behind the head outline. Almost like it is being rendered ontop of the other one with no concern for depth...
Later: Ok, so I looked at all the vertexes in the affected groups, and every single one of them is 100% to Head. Exactly where I want them. Then I checked comments, they are all set to 3 like you said. I'm not really sure what to try now.
Even Later: I gave up on trying to add groups, that was a bad idea and a half. I started over with a new set of hairs, the flypigtails, they, except toddler, have 5 groups each. This fixed most of my spinny problems, except for the toddler one. That kinda makes sense. Now I will have to only worry about trying to make it work once, instead of 3 times. Though, I'm really confused why the teen version worked before,... Once I figure that out, maybe I'll be a bit closer to getting the toddler one worked out.
Dr Pixel
6th Oct 2007, 02:49 AM
The "depth" problem is what I was attempting to explain before - the "alpha" groups must be correctly layered (the opacity settings) or they won't render correctly.
So when you are converting your mesh to the toddler, you have to be careful when changing the group comments - the group names must match the toddler's group names but you still want the opacity settings of the different layers to stay the same as your correctly working adult version (or whatever version it was that you did get to work right)
Phaenoh
6th Oct 2007, 03:03 AM
That doesn't really make much sense. The comments are identical from the different ages, I just imported the child mesh onto the other sizes, so the ones that aren't working for the toddler are identical to the ones that are working for the other ages. Currently the only thing that is different at all is the original number of groups from the hair. That should mean that my problem formed when I added groups. I think I just troubleshooted myself again. Off to try that possibility.
Phaenoh
7th Oct 2007, 04:29 PM
SWEET ACTION!!!!!!!!!! It took me freaking forever, but I FINALLY got a working package with 5 groups for all ages!!!!!!!!!!! bLURR's suggestions at the bottom of HP's tut did the trick for me. Now I just have to go redo everything. THERE IS HOPE AGAIN! I might finish yet! (I'm excited, can you tell?) :: does happy dance ::
Later: Almost everything is done, I'm so happy. So obviously something has to go wrong. Two things have. First, the toddler hair is STILL not being cut by the alpha layer like all its counterparts are. Second, I've got no idea what when wrong with the adult hair mesh. I created my mesh as a child hair originally, then I exported all layers except the hair layer and made it a teen hair, resized, etc, then made that one the adult hair. Something got lost in translation between teen and adult hair. All the comments and bone assignments stayed intact, so I don't know what to check next. Any ideas?
Meanwhile, I'm gonna go start writing that Tips and Tricks on Hair Meshing Article...
tiggerypum
8th Oct 2007, 12:51 AM
There already is a set of hair related articles in the infocenter, so if you write something to add to them, let me know and I'll add it.
My limited experience in the meshing stuff and age conversions is that i had to retain the names used *by the particular mesh I was replacing*. Not all hair meshes use the same naming convention for the groups. Everything has to match up regarding groups, names, names in the comments (so if you change the name you also have to fix the comment to match) and so on for the textures to link to the groups correctly.
As for the toddler, I would check transparency and.... the other part of the group - it'll say something like 'simskin' or something else. If it says simskin - it will alpha to *skin*
Dr Pixel
8th Oct 2007, 01:02 AM
The toddler's hair curls are alpha-ing to skintone rather than transparent -
Possible causes - they are grouped into the "hair" group rather than an "alpha..." group
In the recolor .package, check material definition files -
the "hair" group should have:
stdMatAlphaBlendMode: none
all "alpha.." groups should have:
stdMatAlphaBlendMode: blend
Also check the cMaterialDefinition tab for each -
It should say SimStandardMaterial, not just StandardMaterial
In the mesh .package, check GMDC/Groups tab
Click on each group name and check it's Opacity setting
"hair" group should be 0xFFFFFFFF
"alpha" groups should be the same as the alpha group number (but in hex)
One of these should fix it.
The other one, I'm not sure. Since you do have a properly working version, the best thing is to compare the two and see what is different about them.
Phaenoh
8th Oct 2007, 01:52 AM
HOT D4MN! Thanks Dr. Pixel! The toddler mesh is now working perfectly. The one thing was set to "none" instead of "blend" and the cMaterialDefinition tab for all its groups was "SimSkin" (It was cloned from a 1 group hairstyle, so that makes sense). Now on to troubleshooting that adult mesh...
Just tried an old package that was before I combined all the ages into one. Same bug persists. I was starting to check my recolor package, but then thought that would make much sense either, because this same thing is happening to the YA and elder as well as the adult, so I'm thinking it has to be a problem in the mesh itself, or buggy in both mesh packages. Is there any place else it could be that would affect all three ages? Once it gets to the recolor package its called three different times, so that would be the place to look if one was bad and the others weren't. I'll go check out that mesh. Do bone assignments switch left to right between teen and adult? Cuz my hair bug kinda looks like that.
WesHowe
8th Oct 2007, 02:10 AM
I just want to say I am SO enjoying this project in a vicarious sense.
I haven't seen this much enthusiasm for a project in some time, it reminds me so much of the learning-by-doing and tip sharing from 2 years ago and before.
<* Wes *>
Phaenoh
8th Oct 2007, 02:16 AM
Good to know that I'm not just wasting posting space. (is that possible on the internets?) I was afraid people were just putting up with me till I shut up again...
WesHowe
8th Oct 2007, 03:33 AM
There is at least one thread archived on MTS2 that had a couple thousand posts in it. The end result is what is known as CEP.
I do not know that anything quite as detailed as that is happening here. But, if you keep your resolve up and create a Tips and Tricks document, then TWO good things will have come of it (number one being your new hair mesh creation).
I think if some were just tolerating you, the number of replies made and the response time to answer would be much lower. I do not feel that way, and I have been known to have a lower tolerance for stupidity than some others.
You have a right to be proud of what you did.
<* Wes *>
Phaenoh
8th Oct 2007, 03:55 AM
Coolies!!! That Tips article will definitely get written. I live off the tutorials here, so its the least I can do.
I have a feeling that I won't be the next Nouk, hair creation isn't my passion, never was, still isn't, but I like to know how to do everything, so I'm very glad I went through all this.
I'm generally very quick with picking things up, and I was shocked at how much difficulty I was having on this. That generally means a fault in the lesson, and in this case, there wasn't a complete overview big picture like tutorial that would have saved me from starting over atleast 2 of the 3 or 4 times that I did. I'm still new enough so I have the right perspective for helping out other noobs. I think I might write two things, the big picture one, and a troubleshooting one. I ran into more than my fair share of problems with this I'm sure. lol
The Next Day: Still have no idea whats wrong with that adult one, so if anyone has an epiphany about it later, please let me know!
Phaenoh
8th Oct 2007, 08:29 PM
Ok, I've been looking at everything. I've looked at both the mesh and the recolor packages, I can't seem to find anything different between the adult parts and the other ages. I tried replacing the old busted mesh with a fresh copy, but that didn't work, its still the same weird problem. Then I tried seeing if it was a problem with the joint assignments in the mesh itself. I noticed that simpe didn't register any l_hair or r_hair assignments on any of the ages, and that was weird because I know I used them. The picture I included is what happens when some of the l_hair joints are made to be r_hair. They end up much higher than they should be, as shown by the teen hair next to it. Arg, what do I do now?
Dr Pixel
9th Oct 2007, 04:37 AM
No, the joint assignments would not be reversed from the adult to the teen - in actual fact adults and teens share the same skeleton, the teen's is automatically pre-shrunk by the game just like you can do manually using the "stretch skeleton" cheat in the game.
A question - was the original adult hairstyle mesh that you cloned your .package from the same hair style as the teen's mesh?
Most of the time they are, but there are a few that are not.
The reason I ask is because those "_hair" joints don't always seem to work the same way in every mesh. It's something to do with the settings in the CRES, but there are so many settings in there for body and hair meshes I don't think anyone has ever worked out exactly what setting affects what...
If the adult mesh was in fact a different hairstyle than the teen's I would suggest you try assigning the adult mesh without using any of the "_hair" joints at all, to see if that fixes it.
Phaenoh
9th Oct 2007, 08:11 PM
I didn't really understand what you asked, so I will just try to explain everything I did for that part and hope some of it was what you were asking for.
I originally started with the flying pigtails because it had enough groups. Unfortunately, for all ages, part of the pigtails are in the hair mesh so instead of actually editing that one, I started with other hairstyles to get my hair group. Then I imported my completed child mesh on top and scaled it and move it, then deleted the hair group that came with that one, leaving the one that was originally an adult hair group, so I wouldn't have problems with gaps in random places. Fixed group names, comments, and bone assignments and called it good.
I'm going to go reassign everything in the adult mesh to head, and see what that does. That should be a decent diagnostic.
Later: CURSES!!! That 'fixed' it. I was SO hoping I wouldn't have to redo those bone assignments. So yes, now everything is displaying properly, and I just have to go back and fiddle with the animation bone assignments again...
Thanks everybody!
Dr Pixel
10th Oct 2007, 02:01 AM
Short version -
Since the teen conversion worked correctly, my suggestion (instead of re-doing all the assignments):
(assuming it is an exact match of the teen hairstyle)
Clone the adult version of the same Maxis teen mesh that you used
Link it to the color .package
Import that into MilkShape
Import the working new teen hair mesh (with assignments and all)
Convert that one to the adult mesh.
Phaenoh
10th Oct 2007, 04:02 AM
Thats what I did originally. I'm almost done fixing the assignments anyways, its okay. Wait, maybe I didn't.... I used four random different meshes for each age to get my hair group, then just moved my working child hair to the other ages... Well, I'll know better next time!
Phaenoh
10th Oct 2007, 05:42 PM
Ok, I did redo it like you suggested Dr. Pixel. It works properly now.
THANKS EVERYONE!!!! I"M FINISHED!!!!
Both the final hair with all its recolors and the tutorial that I promised will get posted after I finish up my contest entry. Now SHIRLEY TEMPLE can have her Goldilocks curls, all thats to you all! YAY HURRAY!!!
Phaenoh
17th Oct 2007, 11:35 PM
Double Hurray! I've posted my 'tips'. lol, it ended up being a full-blown tutorial. Linky -> http://www.modthesims2.com/showthread.php?p=1797466#post1797466
vBulletin v3.0.14, Copyright ©2000-2013, Jelsoft Enterprises Ltd.