is my model correct

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
joshua1091
Posts: 23
Joined: Thu Aug 09, 2007 5:16 pm

is my model correct

Post by joshua1091 »

hi i have a model with two separate parts(above hip and below hip)
i did this so that i can rotate the upper part up and down in response to mouse movements,in order to enable the model to aim it's target in game,dynamically.
the leg part will have builtin animation for walking.
why i did this?
the aiming part of the game(aiming at a target)is a dynamic one,which depends on user input(the mouse movement).i thought i could use the joint animating feature for this.the problem is when i animate this joint i cannot use the walk animation from leg at the same time.
so i separated the meshes into body and legs.
now the problem is,when i want to bend the body above hip,it bends as if it a separate object(of course it is).it causes a gap between the two meshes.so,i thought if it is possible to combine(weld) the vertices at the point where the body and leg joins,it will be realistic when i have to bend the character...

is there a solution for this or is there any alternative methods to design a FPS character,so that i can dynamically control the rotation of the hands depending on the user's mouse movement
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

This should have been posted in one of the help forums, not the projects forum.

I imagine what you've got going on is the torso model is rotating (or bending as you say) about its centre, whereas you want it to rotate about the bottom part of the torso instead.

There's two ways of solving this that i can think of...

One is to use a more complicated transformation when you want it to bend which basically requires moving the desired centre to the local origin, rotating and then moving it back... not quite sure if that's how it would work in irrlicht...

Another option that may work is that you've probably modelled the torso so that the model's origin is in the centre of the mesh. You could try making the bottom of the torso be at the model's origin (i.e. the origin of the modelling programs coordinate system) and then that might do the trick...
Image Image Image
joshua1091
Posts: 23
Joined: Thu Aug 09, 2007 5:16 pm

Post by joshua1091 »

thanks...looks like the second option will work....
and sorry i didnt post this in help forum..all i remember is clicking on post reply button in bottom of a page
Post Reply