AMOSi:Col

From Amiga Coding
Revision as of 01:51, 17 November 2007 by Spellcoder (talk | contribs) (1 revision(s))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

an example can be found on AMOSPro_Tutorial:Tutorials/Collision_Detection.AMOS


Checks for the other objects involved in a collision you've just detected using one of the BOB COL,SPRITE COL, BOBSPRITE COL and SPRITEBOB COL functions.


target is the number of the object you wish to test. If it's collided with your source object, you'll get a value of -1, otherwise 0 will be returned.


c=Col(target)

If you enter a target of -1, AMOS will return the number of the FIRST object which has collided with your source object.