4 August 2009
Simple math equations can be used to create the effect of thrust and velocity. This effect is useful for creating spaceship elements or other objects that fly through space while being affected by physics. An object in thrust motion travels in a direction and velocity that either accelerates to a maximum speed or decelerates to a stop.
This sample demonstrates a spaceship-style element that thrusts through space in a direction. Press the up arrow key on your keyboard to thrust. Press the left and right keys to change direction.
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. Permissions beyond the scope of this license, pertaining to the examples of code included within this work are available at Adobe.