FANDOM


The Collision event will trigger when the caller collides with the given object's instance.

  • Both object's sprites need a collision mask defined.
  • Without physics: the room must not be a Physics World, both objects can be solid or not.
  • With physics: the room must be a Physics World, also both object need separate physics Collision Shapes (when using physics, sprite masks are unused).

Collision functions check a point/rectangle for an existing object.

  • place_empty(x_coord,y_coord) - true if the caller would not collide with any instance
  • place_free(x_coord,y_coord) - true if the caller would not collide with any solid instance
  • collision_point - check a point for a specific object's instance
    • x_coord/y_coord: point to check, object: the object whose instance is searched, precise: true/false, notme: exclude the calling instance? (true/false)
    • returns the <instance-id> or noone.
    • not much use if you don't catch the result inside a variable or statement:
collision_result = collision_point(x_coord,y_coord,object,precise,notme);

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.