PDA

View Full Version : Realistic arm movements.


room14
01-07-2012, 05:35 PM
I have an idea that just might work instead of having to make the arm movements by hand, I might be able to automate the movements using complicated math involving trig and other math.

this means you can move the gun in more complected ways than ever, without the complicated codes and try and error. also you can re-arrange the gun without recoding.

this also adds the ability to draw out weapons rather than spontaneously spawning them. -Realistic 3rd person view.

arty-fishL
01-07-2012, 06:04 PM
Well, if you can get it to work, that would be great :D. I'm slightly sceptical though; in my Air Ace game I used fairly advanced maths that I thought would be really easy to implement, but I confused myself completely, I eventually ended up doing it somehow anyway.

room14
01-07-2012, 06:09 PM
this will be alot easier if the forearm and the biceps were the same length.

Mr Kidnapper
01-07-2012, 06:56 PM
There's an entire field of science on this called "Inverse Kinematics" used to program robots. Perhaps you should research that. It could help.

room14
01-07-2012, 08:35 PM
I know how to do it. but the math would be a lot easier.

x2495iiii
01-08-2012, 04:16 AM
Well, if you can get it to work, that would be great :D. I'm slightly sceptical though; in my Air Ace game I used fairly advanced maths that I thought would be really easy to implement, but I confused myself completely, I eventually ended up doing it somehow anyway.

I know exactly what you mean. I basically use one part math smarts and two parts trial and error when I make up new formulas in my games. I usually know the general idea of what the numbers' relations to each other should be, but not what the values should be, meaning lots of T&E.

jediaction
01-08-2012, 04:09 PM
I have an idea that just might work instead of having to make the arm movements by hand, I might be able to automate the movements using complicated math involving trig and other math.

this means you can move the gun in more complected ways than ever, without the complicated codes and try and error. also you can re-arrange the gun without recoding.

this also adds the ability to draw out weapons rather than spontaneously spawning them. -Realistic 3rd person view.

Ah, very good. I've tried many times doing animations and It's what I specialize in. I find it the most fun to. I usually work on my gun reloading animations. I have been working on a new animation. Not in Alice, but in reality. I've been figuring out what looks like the coolest animation and I figured it out. Changing weapons animations won't be that difficult. Once you get the math right, it's fun from there. I think I have projects with animation tests around the community if you need som help. Now, you say spawning? I'm not quite sure what you mean by "spawning."X helps a bit though above.

room14
01-08-2012, 04:42 PM
Ah, very good. I've tried many times doing animations and It's what I specialize in. I find it the most fun to. I usually work on my gun reloading animations. I have been working on a new animation. Not in Alice, but in reality. I've been figuring out what looks like the coolest animation and I figured it out. Changing weapons animations won't be that difficult. Once you get the math right, it's fun from there. I think I have projects with animation tests around the community if you need som help. Now, you say spawning? I'm not quite sure what you mean by "spawning."X helps a bit though above.

instead of instantaneously getting an item from thin air.

room14
01-08-2012, 05:15 PM
I drew this diagram to explain the math.

just from alice you can find the values ab, bc, ca.
but that is not enough to find the angles.
what we need is line bd, ad or dc.
using heron's equation, we can find the area.
T= sqrt s(s-l.ab)(s-l.ba)(s-l.ca) s meaning semiperim.

and using the area, we can find the value l.bd
then we can find the angles using trig.

simple.

AliceMaster00
01-08-2012, 05:24 PM
I wish i were in high school or college cauz, THIS MAKES NO SENSE TO ME WHATSOEVER!!!!!!!!!!!!!!! Ima middle schooler, not a supercomputer! In need to know how to get realistic arm movement!!!!!!!!!!!!!!!!

jediaction
01-08-2012, 09:22 PM
I wish i were in high school or college cauz, THIS MAKES NO SENSE TO ME WHATSOEVER!!!!!!!!!!!!!!! Ima middle schooler, not a supercomputer! In need to know how to get realistic arm movement!!!!!!!!!!!!!!!!

Haha. Well, some members are making extremely advanced stuff like ARty-FishL. He is working on Controller Input for Alice, and he has his own theme system. I'm working on a multiplayer game with another long time member who isn't as frequent in the community, but frequent on Skype.

I drew this diagram to explain the math.

just from alice you can find the values ab, bc, ca.
but that is not enough to find the angles.
what we need is line bd, ad or dc.
using heron's equation, we can find the area.
T= sqrt s(s-l.ab)(s-l.ba)(s-l.ca) s meaning semiperim.

and using the area, we can find the value l.bd
then we can find the angles using trig.

simple.

So, I'm a bit confused on how the system would work. Explain to me again how this would be different from "mid Air Spawning" and what did you mean btw? Like "is showing = true/false?"

InsertName
01-08-2012, 09:23 PM
This is serious stuff, even some professional game making companies don't bother with realistic arm motions.

room14
01-08-2012, 09:51 PM
I wish i were in high school or college cauz, THIS MAKES NO SENSE TO ME WHATSOEVER!!!!!!!!!!!!!!! Ima middle schooler, not a supercomputer! In need to know how to get realistic arm movement!!!!!!!!!!!!!!!!
Hey, relax. It's not so hard. I am only entering high school this year.

So, I'm a bit confused on how the system would work. Explain to me again how this would be different from "mid Air Spawning" and what did you mean btw? Like "is showing = true/false?"

yes instead of a weapon suddenly becoming visible, it would be located on their body and be able to pull it out.

x2495iiii
01-08-2012, 09:59 PM
I don't know for sure, but I'd assume that most developers would only do the math once, then delegate the process to a preset animation, since the gun should go to and be drawn from the same place every time.

room14
01-08-2012, 10:53 PM
I have bee trying this in alice. and I have hit a snag.
for some reason, the arm is miss ing the length completely.

edit: i fixed it. it works!
note it is just a proof of concept and is very glitchy.

jediaction
01-09-2012, 08:50 AM
I'll have to try it when I have time. Glad it works. Can't wait to see it.

arty-fishL
01-09-2012, 12:36 PM
Sooo, how do you use it?

x2495iiii
01-09-2012, 02:27 PM
Sooo, how do you use it?

This.

jediaction
01-09-2012, 04:35 PM
Testing now...


EDIT: Ok....I agree with Arty....Sooo, how do you use it?

Also, what do you mean X?

legolizard
01-09-2012, 05:40 PM
That is cool, Math + programming = awesomesauce(and rage). :p

Also jediaction I believe Mr.X was correcting Arty-FishL is his statement in that it should be :
"Sooo, how do you use this."

room14
01-09-2012, 07:08 PM
you can't use it yet, it's just a proof of concept. this makes it possible to touch or hold an object that is in their grasp. with out coding at all. this can be use for basically all of you hand movements

jediaction
01-09-2012, 09:09 PM
Ok Then. Can't wait to see it in action.

Mr Kidnapper
01-09-2012, 09:49 PM
Lol. When I said Inverse Kinematics I didn't mean any fancy 3D modeling stuff. They take a part, figure out where it needs to go, and use math to rotate the required parts so that it gets there.
Here's a great link that can explain the premise
http://freespace.virgin.net/hugo.elias/models/m_ik.htm
Haha. I look at it and notice that it requires a bit of calculus, but don't worry. Physics can be done algebraically fairly easily, as long as you know what equation to use.