cpShape

Opaque collision shape struct.

Members

Variables

bb
cpBB bb;

The current bounding box of the shape.

body_
cpBody* body_;

The rigid body_ this collision shape is attached to.

collision_type
cpCollisionType collision_type;

Collision type of this shape used when picking collision handlers.

data
cpDataPointer data;

User definable data pointer. Generally this points to your the game object class so you can access it when given a cpShape reference in a callback.

e
cpFloat e;

Coefficient of restitution. (elasticity)

group
cpGroup group;

Group of this shape. Shapes in the same group don't collide.

hashid
cpHashValue hashid;
Undocumented in source.
hashid
cpHashValue hashid;
Undocumented in source.
klass
cpShapeClass* klass;
Undocumented in source.
klass
cpShapeClass* klass;
Undocumented in source.
layers
cpLayers layers;
Undocumented in source.
next
cpShape* next;
Undocumented in source.
next
cpShape* next;
Undocumented in source.
prev
cpShape* prev;
Undocumented in source.
prev
cpShape* prev;
Undocumented in source.
sensor
cpBool sensor;

Sensor flag. Sensor shapes call collision callbacks but don't produce collisions.

space
cpSpace* space;
Undocumented in source.
space
cpSpace* space;
Undocumented in source.
surface_v
cpVect surface_v;

Surface velocity used when solving for friction.

u
cpFloat u;

Coefficient of friction.

Meta