At 10/21/09 04:23 PM, Toast wrote:
Err, nope. Don't you know that gravity is gone when your feet touch the floor? Seriously, go learn some physics before you try to make flash games.
LoL
At 10/21/09 09:59 PM, Version2 wrote:
Let's see... Triangle devided by a coeffiecent and some pie... Nope, he's absolutely correct. As soon as your feet touch the ground, gravity goes away. Also, space ends 12 miles up... according to these calculators.
Haha
Okay lets get a little more serious now. :)
At 10/20/09 10:21 AM, iluvAS wrote:
2. that eular rule thing.
Which one? Euler was a damn famous mathematician and there are tons of "euler things" basically his whole life work!
As to how slopes work:
Gravity pulls you down, also on a slope but there you split up the gravity vector into a component that is normal to the collision surface and one that is tangential to the collision surface. That way the normal component will push him up and make him not collide whereas the tangential component will make him slide.
If you are art based its trickier to find out the normal vector, basically you have to take sample points in player center and at least one or two more on one or both sides ie. slightly displaced on the x axes. With the sample points you calculate the normal vector and use that one to calculate the gravity distribution ect.
You could also have movieclips that are rotated and calculate the normal based on the rotation and voronoi region.
You could also have a tile engine with precalculated/preset normal vectors.
Now the problem is this all requires basic vector math and a brain to do, and i certainly don't have the time to write out the code for you. So there are 3 options left, either someone else does, you go and learn it (using google) or you simply give up. :)
cheers