New answers tagged position
I think some trigonometry classes would help you. Meaning of variables position.x is the x coordinate, and position.z is the y (if 2D game) or z (3D game) coordinate. Yaw is the rotation (in radians I think). So when user presses A do yaw--; and when user presses S do yaw++;. Distance is how far to move (sort of like speed). NOTE: This is written in Java. ...
Top 50 recent answers are included