Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
1 registered members (TipmyPip), 18,513 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: Bone orientation - Local vs global [Re: Germanunkol] #362809
03/09/11 18:25
03/09/11 18:25
Joined: Apr 2005
Posts: 4,506
Germany
F
fogman Offline OP
Expert
fogman  Offline OP
Expert
F

Joined: Apr 2005
Posts: 4,506
Germany
Thumbs up! I´ll test it asap!


no science involved
Re: Bone orientation - Local vs global [Re: fogman] #362826
03/09/11 18:51
03/09/11 18:51
Joined: Apr 2005
Posts: 4,506
Germany
F
fogman Offline OP
Expert
fogman  Offline OP
Expert
F

Joined: Apr 2005
Posts: 4,506
Germany
Ok, it seems to work for my project.
Thank you very much again, I´ll try to get my head around it.


no science involved
Re: Bone orientation - Local vs global [Re: fogman] #362862
03/09/11 20:40
03/09/11 20:40
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
You're welcome laugh
Was a welcome break from studying...


~"I never let school interfere with my education"~
-Mark Twain
Re: Bone orientation - Local vs global [Re: Germanunkol] #363148
03/11/11 09:47
03/11/11 09:47
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline
Senior Expert
HeelX  Offline
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Hi,

I looked into the demo and the model - and I have a very dumb question (without calling your project and your requirements into question): why don't you just simply animate all operations on the vehicle in animated bone sequences and wire them together ingame? This would also lead to less code overhead that is specifically designed for each vehicle and also gives you the opportunity to encode subtle animations like rotating/moving bolts or so. Because: all I see are simple animations, encoded to some keys in horizontal and vertical direction (without knowing what other operations you have planned on e.g. other vehicles, though). So in your case, a sequence "HLeft" and a sequence "HRight" could cover horizontal rotation from -1..0..+1 and a sequence "VUp" could cover the up-animation. Inside the animations you could make sure, that your hydraulics are correct and beautiful!!

From a technical point of view, the Gamestudio bone system has a major disadvantage which makes it not THAT easy to realize a "entBonerotateTo"-function. I did a while ago (2 yrs?) a facial animation system for a Gamestudio game with high def characters, in which they should turn their head towards the camera when the player is approaching and when the character can't turn the head anymore, the eyes should follow according to the camera position. During development, I found out, that in the initial configuration of the model, MED (or Gamestudio in general) doesn't save the appropriate Euler-angles which were used in MED to orientate the bones. This way, every bone, regardless how orientated, has the rotation (0,0,0). This way, you CAN NOT rotate the bone sequence back and forth to gain a bone, orientated to a specific position!

To solve this issue and make the animation system work with the camera position I adviced the rigger to create bones from the Root to the Neck to the eye bones that way, that they are ALWAYS aligned to either the X, Y or Z axis, so that I knew apriori the initial bone rotations. This way, I was able to re-rotate the bones and rotate the head and the eyes according to arbitrary positions in space, regardless of the pan and position of the character.

I also tried to reconstruct the orientation of the bones by taking the positions of the bones, their difference vector and the vec_to_angle function, but the mathematical problem is, that you have only two positions which define an axis. And as long as you look along this axis, you -cannot- determine, which rotation angle around this axis you have - this was very problematic, especially with the eye bones. In YOUR case, you could do that, though, I believe, if and only if you use special restrictions, like having all bones on the XZ-axis (--> y = 0). This way, you could reconstruct your angles appropriately.

But nevertheless, this would also lead again to very much code overhead and if I were you, I would fear, that I would have to write special code for each vehicle. And if you change your rig, you will have to adapt it. Otherwise, if you just execute animations, you are loosely coupled in that domain and you can change your animated vehicle in your modeling app as you wish and it works directly if you keep your animation names.

I hope that gives you (and others) some insight into this problem.

Last edited by HeelX; 03/11/11 09:48.
Page 2 of 2 1 2

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1