Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / clothing and armor problem

Author
Message
Jasonorc
16
Years of Service
User Offline
Joined: 29th Apr 2008
Location: Turn around...
Posted: 17th May 2009 21:16
Hi, very tricky problem this time, i searched and no-one had a real answer.

I'm basically developing a 3d rpg, and have made the hero graphic, and animated him just fine. But now how do I attach armor or shirts or trousers and so forth (thats I have lready made) without making the hero look screwy when he moves.

Not only that, It's best if I can do it from dbpro, maybe using an ovelray, as I intend to have a few hundred items you can pickup and wear, not even going near the weapons! So how do I attach an armor or shirt or weapon to my characters graphic through dbpro? Or is this too much to ask, if so how would I go about doing this in any way?

My site: www.skyknight.co.uk
ShaunRW
DBPro Developer
16
Years of Service
User Offline
Joined: 7th Jan 2008
Location: Brisbane, Australia
Posted: 18th May 2009 03:01
Update the position of the clothes to the same as the player. makes it look like the player is wearing it.


BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 18th May 2009 03:47 Edited at: 18th May 2009 03:50
That won't work if the player is animated, though, which I assume is your problem. Here are my thoughts:

Try to break the clothing and items down into "static" items that don't necessarily need to deform with the player, like backpacks and swords, and "dynamic" items that do, like shirts, pants, and boots.

Static objects can be easily achieved through ShaunRW's method of just constantly positioning the object at the right position relative to the player, or even more easily through the command GLUE OBJECT TO LIMB.

Dynamic objects will be more tricky. You have three options that I can see:

1.) Use the new Cloth commands to create clothing, and attached this clothing to the player. Upsides: This will create awesomely realistic animations as the cloth sways, wrinkles, and deforms around the player just like real clothing would. Downsides: It will require a LOT of tinkering and possible vertex manipulation, because as of yet the MAKE CLOTH FROM OBJECT remains an idea.

2.) Rather than add on new objects to the player for shirts and pants, simply retexture the affected areas. Upsides: Comparitively, very easy to accomplish. Downsides: Doesn't allow for new geometry to be added such as baggy sleeves, belts, and pockets.

3.) Create seperate objects for the pants and shirts, and use the limb positions of the player along with vertex manipulation and mesh deformation to bend the objects so they look like they are on the player. Upsides: Looks better than method 2 while being much more possible than method 1. Downsides: It will most likely still take much fiddling to get the mesh deformation to wrk how you want it to.

There's my two cents .



Cagedrei
15
Years of Service
User Offline
Joined: 18th Mar 2009
Location:
Posted: 18th May 2009 07:55
You could also create the clothing as separate animated figures which duplicate the animations of your player. Then make sure the clothing figure follows the player figure, as noted above, and just keep the animations for the two figures synchronized.
Jasonorc
16
Years of Service
User Offline
Joined: 29th Apr 2008
Location: Turn around...
Posted: 18th May 2009 08:45
Thanks everyone, so far so good. Bmaczero-what commands would I need to do then, if there isn't the create cloth command yet?

I think if I can use that I shall, if not I'll overlay the image and maps of the clothes onto the basic figures, and with the armor have it cut down and I'll glue it on limb by limb...

My site: www.skyknight.co.uk
BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 18th May 2009 16:12
@Cagedrei - That is an option, but a difficult one because you'd have to rig and animate each of the "a few hundred items you can pickup and wear" and do it exactly the same way on each.

@Jasonorc - I think the cloth commands were added in version 7.4, so you'll most likely need to upgrade. They don't have help files, but this should help. There are MAKE CLOTH commands, however the problem is that the cloths are flat sheets, and it's difficult to make them into closed loops like shirts and pants. I don't think you'll have much success at this, unfortunately, I'd go with the other you have chosen.



Cagedrei
15
Years of Service
User Offline
Joined: 18th Mar 2009
Location:
Posted: 18th May 2009 22:07 Edited at: 18th May 2009 22:11
Quote: "@Cagedrei - That is an option, but a difficult one because you'd have to rig and animate each of the "a few hundred items you can pickup and wear" and do it exactly the same way on each."


Ah. I use Blender, which has a few scripts to make it easy to transfer a skeletal rig to a new mesh (of compatible shape), after which porting over the animations is a breeze. I don't know if it's as easy in any other 3D development package. Hmm.

There are some decent custom cloth code snippets in the DBPro coding challenge thread. At least one of them looks like it might be adaptable to the problem of handling a custom model as cloth. The problem then would be handling collision with an animated figure, as that isn't covered in the snippet. But developing something based on that might be, as they say, non-trivial. And possibly slower than one would want, being coded directly in DBP rather than handled by a plugin. Hmm.
Jasonorc
16
Years of Service
User Offline
Joined: 29th Apr 2008
Location: Turn around...
Posted: 18th May 2009 23:30
Ok we've discussed it and for armors and such, I'll cut it into 3 or 4 peices and glue it to the various limbs, and retexture maybe 10 or 12 armors to create the many armors in the game. Same for weapons, just glue it.

Overlaying clothes sounds a bit odd though, wouldn't a magic cloack that should not be stuck to a dudes legs...well not be an image over a dudes legs, giving the appearance of a man with a really tight fitting cloack?

I made no sense there did I?

My site: www.skyknight.co.uk
BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 19th May 2009 01:58
For a cloak, you should be able to use the cloth commands faily easily, because it doesn't need to be a closed loop. Just attach a cloth to the guy's soldiers and let it trail.



SAAB Driver
18
Years of Service
User Offline
Joined: 1st Nov 2005
Location:
Posted: 19th May 2009 23:55
Else you could try "Glue object to object" command

Hello!

Login to post a reply

Server time is: 2024-09-28 06:18:52
Your offset time is: 2024-09-28 06:18:52