qaf::CollisionStruct::Composite Class Reference

#include <qafCollisionStruct.h>

Inheritance diagram for qaf::CollisionStruct::Composite:

qaf::CollisionStruct qaf::Container< T > List of all members.

Detailed Description

Represents disjointed collision shapes.

Using a composite collision structure allows the representation of non-contiguous areas, or complex shapes that would otherwise require a polygon.

The Composite class is, essentially, a Container of CollisionStructs, so you can use any method from the container class to add, remove, and manipulate its elements.

Warning:
Elements added to the composite will not be deleted automatically. You must delete them yourself.


Public Member Functions

 Composite (CollisionStruct *const elems[], int nCount)
 Initializes the composite with the supplied structures.
 Composite ()
 Initializes an empty composite.
void render (float scrollX, float scrollY, unsigned long color)
bool collidesWith (CollisionStruct *otherStruct)
bool hasPoint (float x, float y)
bool pointIntersection (float x1, float y1, float x2, float y2, Vector2D *pContact, Vector2D *pNormal)
void move (float dx, float dy)


The documentation for this class was generated from the following file:
Generated on Sun Mar 25 12:32:13 2007 for Qaf Framework by  doxygen 1.5.1-p1