Category: 2D Game Physics (Pro)
BodyVelocityX(body As Integer)
Double
Returns the body's horizontal velocity in pixels per second.
Invalid handles return 0.
Pro feature: compiling code that uses this function requires a license with the GamePhysics feature enabled.
If KeyDown(KEY_RIGHT) Then SetBodyVelocity player, 220, BodyVelocityY(player)