How to create models in XSI and other 3D applications and make them work in Battlefront 1 & 2. Post models, tips for application usage and share anything XSI, 3DMax, SketchUp, etc.
Well, here i am again, again with wanting something to have properties with movement... First, it was my tentacle tut, now, it is something else...Right! I've got a marvelous idea, but i need some confirmation from good skilled moddelers (hint Ace ) if this will work... It's about an addon-/boltonmsh.. I thought, what if you create let's say a belt as addon mesh, and IN the addon mesh add a kama? Will this work with clothing props etc.? The kama will be added to the belt using Ace's fantastic cloth tut ofcourse:
Hidden/Spoiler:
[code]First off create your character and cloth object and texture them or do whatever you have to do.
Make your cloth object a child of "dummyroot".
Then envelope your character mesh to the bones and edit the weights.
Now envelope your cloth object.
If you made a cape and it drapes down from the neck area just envelope the cape object to both left and right clavicle bones or maybe just the neck bone, play around with it to get the best results ingame.
If you made a kama then just envelope it to the pelvis bone.
This is so the cape object will follow your unit properly, such as when jumping, rolling, crouching and so on.
Now we need to make some cloth collision, go to:
Get>Primitive>Polygon mesh>sphere or cylinder(i've seen both used by Pandemic)
and scale it down with the PPG to keep the primitive properties then translate it into place, do not freeze their transforms, add as many spheres as you think you need to keep the cloth from flowing through the legs and body.
Rename your cloth collision spheres c_somename, c_somename1 and so on or whatever and make them a child to the bone that you want them to move with.
Most of the shipped cloth collision primitives made by Pandemic were named after the bone that they move with, such as:
c_ribcage, c_l_thigh, etc....
Now select your cloth object and and go to the "Pandemic Tools" and click on "Create Cloth".
A property page will come up.
At the top of the ppg(property page) you will see a section titled "Collision", in that section you will also see a button that says "Select Collision Objects", press that button and a picking session will begin.
Select all of your cloth collision primtives(ex: c_whatever) then right click to end the picking session.
Now with the ppg still open you will see another section titled "Fixed Points".
Fixed points are the vertices on the cloth object that will attach to the player model, in other words these are the vertices that will ignore the cloth properties(deformation) making it look like the cloth is attached to the player.
For example, if you're making a cape that starts around the neck just select the top row of vertices on the cape object and that will be the fixed portion of the cape.
Close the ppg and you're done, hide(press H on your keyboard) your hp_weapons, bones, dummyroot, sv model, and collision primitives then branch select(middle mouse click) dummyroot and export your model giving it a name and save destination.
Now you need to set up the cloth ODF, just copy one from the assets and rename it to whatever the name of your cloth object was in XSI.
Inside that cloth ODF enter the mesh name of your exported unit:
attachedmesh = "name_of_exported_mesh " (without the ".msh" part appended)
Don't forget to enter the code in the unit's ODF to enable the cloth ingame:
ClothODF = "name_of_your_cloth_ODF"
I also noticed that the more polygons that your cape has then the better it will deform ingame, but there are a few properties you can add to the cloth ODF to make it deform how you want.
From the docs:
There are other properties that you may have in a cloth ODF – we have rarely had occasion to use them, but they are:
(Note that [parameter] means a number, like 20.4, not [20.4])
// ---list of optional cloth parameters---
// Angle of the wind, phi and theta
WindDirection = “[angle1 in degrees] [angle2 in degrees]”
// Wind speed, in m/s
WindSpeed = [speed]
// Dampening coefficient – in some unit or other :^) Default is 0.5
Dampening = [number]
// Drag coefficient, also in some unit – default is -2.0
Drag = [number]
// Mass of each cloth “particle” (in Kg?) – default is 1.0
ParticleMass = [number]
// Maximum world acceleration, in m/s/s – default is 20
MaxAcceleration = [number]
// Priority – cloth with lower priority is skipped,
// if not enough time is left this frame – used for the Emperor
// Default is 0
Priority = [number]
// Does this cloth have an alpha channel? 1 or 0, Default is 0
Transparent = [value]
// BF2 has 3 different types of constraints it satisfies each frame
// when computing the cloth:
// “Bend” constraints keep the cloth’s shape.
// “Stretch” constraints keep the cloth’s size.
// “Cross” constraints keep individual pieces of cloth from shearing.
// You can turn these on or off individually by specifying a
// zero for the constraint.
// For example, if you turn off “stretch” constraints the cloth
// can grow longer or shorter…
CrossConstraint = [zero or one]
BendConstraint = [zero or one]
StretchConstraint = [zero or one]
[/code]
I wonder, will this work ofcourse, but also, will it not float true the body (collision)? I think not, because addon-animated tentacles have auto-collision, while animated tentacles added to the unitmesh/bones DO need collision... I'm sorry i haven't just tested this, but i need to find the good coordinates for an addon kama, need to get Ace's tut working and I'm not the best moddeler...
Edit: I'm getting a cape exported which should have cloth props... What i did:
1. Import the BF1 dooku cape, and added the texture
2. Created a null at 0,0,0 and called it bone_root
3. Enveloped the cape to the bone_root
4. Used the Pandemic Addon to ONLY select the fixed verts
5. After that, branch selected bone_root and exported...
6. In the unit odf added the line ClothODF = blablal Question: Should i also make an addon part in the odf like with a common addon, or make the cloth odf refer to the addon, or both?
After this question is answered and I've got the cape exported I'll post results!!!
I don't see why this wouldn't work with the tentacle addon technique, the setup would be basically the same, but bone_root might have to be rotated a different way to properly line up with a different bone that it will attach to.
Cloth is something that i've only seen work when it was exported with a player model or a static prop, when I tried to export a single object with cloth properties without a player model or additional geometry it doesn't seem to work ingame.
The only other shipped object that i've seen with cloth physics is the Flag from CTF modes, but it has a couple of different msh's involved, I might look into that a little deeper also.
You mean actually just using the tentacle way... I know it works, I mean it must work; it's basicly just a tentacle on your back, but still i wondered...
Cloth as an addon presents interesting problems, because, what ace was talking about. Also, a cloth MODL chunk references collision MODL chunks inside of the mesh file. The collision needs to be connected with the leg bones etc. I don't think you could do that, because the collision would have to be in the addon mesh, but the bones can't be in the addon mesh, only the addon. In my mind it doesn't seem to work out.
Thanks for the info Rep... Cloth indeed, is not possible...Still you can get 'cloth' addons (like capes, hats whatever) animated with the nice tut Ace, Gogie and I created in the tentacle post... You must read through the whole topic, then you'll understand it more easily... I hope everyone agrees, but i think this can be locked..