VgaGames4

VgaGames4 - collision man-pages

[.. upper level ..]

# vg4->collision->insert()

Insert object-instance into a collision-tag.

SYNTAX
void vg4->collision->insert(unsigned int ctag, unsigned int instanceid, const struct VG_Rect *rect, int percent)
FUNCTION PARAMETERS

ctag | Collision-tag
instanceid | Instance-ID
rect | Position of object-instance
percent | Percent of using rect calculated from the center, e.g.: rect={5+10,5+10} and percent=80% => used rectangle={6+8,6+8}

DESCRIPTION
Insert object-instance into a collision-tag. To check for a collision with another object-instance, both must be inserted.
SEE ALSO
vg4->collision->remove()