c_updatehull(ENTITY* ent, var frame)

Recalculates the collision hull for the given entity to match the vertex positions of a certain frame or of the current bones position. Also sets the bounding box to the size of the collision hull. Call this function when you need the collision hull of a certain frame, or when you have applied mesh manipulation functions to a frame.

Parameters:

ent - entity pointer.
frame - vertex frame to be used for the hull, starting at 1 for the first frame. Not used for bones frames.

Modifies:

min_x/y/z, max_x/y/z, FAT / NARROW

Remarks:

Speed:

Slow

Example:

wait(1);	// wait 1 frame after creation
c_updatehull(my,10);

See also:

c_setminmax, min_x, max_x, FAT, NARROW, POLYGON

► latest version online