GenSetSpriteAcceleration


GenSetSpriteAcceleration sprite, acceleration, angle {, terminalVelocity }

sprite

Sprite to accelerate.

acceleration

The acceleration in pixels per sec2

angle

The direction angle to accelerate the sprite.

terminalVelocity

This optional parameter may be used to set the terminal velocity of the sprite. When the sprite reaches this velocity it will stop accelerating.


The diagram below shows sprite angle and orientation. Sprites rotate in a clockwise direction. The rotation angle shown below is also the direction angle.


SetOnGenSpriteTermVelSub


Game Engine Overview







Become a Patron