- Home
·
- Math/Dates
·
- Calculates how much an object's X and Y will increase if moved in a certain direction at a certain
Calculates how much an object's X and Y will increase if moved in a certain direction at a certain
Calculates how much an object's X and Y will increase if moved in a certain direction at a certain speed. Useful for calculating the movement
Rate Calculates how much an object's X and Y will increase if moved in a certain direction at a certain
(2(2 Vote))
Function FowardX(rotation, rate As Single) As Single
FowardX = (rate * Cos((rotation - 90) * ((Math.Atn(1) * 4) / 180)))
End Function
Function FowardY(rotation, rate As Single) As Single
FowardY = (rate * Sin((rotation - 90) * ((Math.Atn(1) * 4) / 180)))
End Function
Calculates how much an object's X and Y will increase if moved in a certain direction at a certain Comments
No comments yet — be the first to post one!
Post a Comment