(01-08-2013, 03:47 AM)TheGreatCthulhu Wrote: @str4wberrypanic: You can read about that on the wiki.
In short, these are indicators, or "flags", or so called "magic numbers" which have specific meaning when passed to this function.
When passed as parameter to AddEntityCollideCallback(), they determine when exactly the collision event should be detected:
- 1 means when the two entities (or an entity and an area) first intersect (collision on enter)
- -1 means when they, or rather their bounding boxes, stop intersecting (collision on leave)
- 0 means both
The callback itself has a similar input parameter (alState on the wiki), which you can check to see which event triggered the collision; naturally, it can only be 1 or -1.
Thank you Cthulhu, you're aways helping me.