CSS Logo XNACS1Lib Library Documentation
XNACS1Primitive Methods

Game-Themed Introductory Programming Project   

The methods of the XNACS1Primitive class are listed below. For a complete list of XNACS1Primitive class members, see the XNACS1Primitive Members topic.

Public Instance Methods

Above Returns if the center of this primitive is "above" (in y) in relation to the center of otherPrimitive.
AddToAutoDrawSet Add this primitive to the AutoDrawSet. If this primitive already exists in the draw set, this function call is ignored. By default, all primitive are added into the AutoDrawSet.
Below Returns if the center of this primitive is "below" (in y) in relation to the center of otherPrimitive.
CollidedOverloaded. Determines if this primitive collides with the otherPrimitive. If true, pos is the colliding position.
Draw If visible, draws the primitive with the associated text label.
HasNonZeroVelocity Retruns if the current velocity is non-zero.
IsInAutoDrawSet Determines if this primitive is in the AutoDrawSet.
LeftOf Returns if the center of this primitive is "to the left" (in x) in relation to the center of otherPrimtive
RemoveFromAutoDrawSet Remove this primitive from the AutoDrawSet. After this function call, this primitive will not be drawn in the application window.
RightOf Returns if the center of this primitive is "to the right" (in x) in relation to the center of otherPrimitive
TopOfAutoDrawSet Make sure this primitive is drawn on top of all other primitives.
TravelPrimitive Moves the primitive during each update cycle. This function is automacially called for all visible primitives. Default behavior is to move the primitive if: . Primitive is visible (invivislble primitive is not updated) . ShouldTravel is true . HasNonZeroVelocity() is true

Protected Instance Methods

DrawPrimitive Draws the primitive.

See Also

XNACS1Primitive Class | XNACS1Lib Namespace