   Gravity sliding (collision detection)
  I have my collision detection and response to a point that I believe is stable, i have yet to be able to find any kind of anomalies with it. However when I apply gravity to the velocity vector, I am constantly sliding down anything with a slope that is higher then 0. What is the best solution to this type of problem? Thanks for the help   
  2 things come to mind.Firstly as soon as anything is in rest (IE) velocity set a rest variable in it so you dont process it anymore.. Ofcourse its more complicated because if something goes up its at rest for an instance at its peak so you want to also check that there is a valid obsticle(ground) below it to counter gravity.Secondly, friction.Friction is a retardation in the oppisite direction, the question is how high is friction. Well its quite complicated but to get friction you need thingsGravity = 9.8Friction coefficient  = 0.5Now what is important is the force that is applied to to the object of frictionSee my picR = Ground Normal(direction)    G = Gravity(force vector)  0 = ObjectS = Slide Caused by Gravity||    \|/GR^|   |    0--->S-------------   GroundNow !S (or the retardation of s) == Friction coefficient * Purpendicular Force of OSo if the ground shown at the top is at a 45 degree tilt the total friction will be 0.5 * 0.5 (percent of S) because then it means that 25% of the  Thus !S = s/4This is because||o|------------o is the Angle between the downard force and the plane, so if o is 0 then friction is also = Friction Coefficient * 0.0, if o is 90 then friction = Friction Coefficient * 1.0So grass's typical coefficient will be 0.8 - 0.9Now the last thing 2 remember is that there is MOLECULAR FRICTION or more easily described as STICKYNESS of surfaces, for example prestiek on a wall holding the picture up.All object have this MOLECULAR FRICTION, but it is neglible in this case, and in most cases your friction coefficient will have it worked in.   ;  That helps a lot, I understand coefficients of friction and what not, however my problem is with actually implementing it into code. Would a possible solution be taking the angle between the plane and the gravity vector(or a flat 0 inclined plane), and multiply that by the coefficient of the surface im on. If that value is over over say, some value for the coefficient of static friction, then we would slide, otherwise we stay still?   ;  Friction force (acting parallel to the surface) is always, F = μ * N, where N is the normal reaction from your surface and μ is you coefficient of sliding dynamic friction.Now when the surface orientation changes the normal reaction is what will change. Say your surface is inclined to the horizontal by a angle φ, your normal reaction will be N = mg * cosφ (m is mass, g is accn due to gravity). So when the surface is horizontal (or nearly so), the value of F is somewhat large, and there should be no sliding. If there appears to be any, bump up the value of μ.   