by Walter Eigner (15 Submissions)
Category: Math/Dates
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Tue 20th January 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)
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
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
No comments have been posted about Calculates how much an object's X and Y will increase if moved in a certain direction at a certain . Why not be the first to post a comment about Calculates how much an object's X and Y will increase if moved in a certain direction at a certain .