Can someone create something like this? im trying now for 4 days i can't get it right..
If player pressed "Move Forward" button, get_user_velocity + defined value, direction forward
If player pressed "Move Right" button, get_user_velocity + defined value, direction right
If player pressed "Jump" button, get_user_velocity + defined value, direction up
Also, if the player is having 50 velocity to forward, 30 right, 25 up
If player pressed "Move Forward" button, it wont affect the other directions' velocity, so it will result in
Quote:
Vel[x] = 50 + Value
Vel[y] = 30
Vel[z] = 25
|
something like
Quote:
if (button & in_forward)
velocity[x] = get_user_velocity[x] + defined value
velocity[y] = get_user_velocity[y]
velocity[z] = get_user_velocity[z]
|