splitting instances

This forum is currently in read-only mode.
  • if 2 instances collide how do you give them each another action to do?

    the instances where created in runtime, so i can't give them a fixed number, my problem is mostly how can i pick them apart?

  • The easiest way of doing this is to add the object into a family, then checking for collisions between an object and the family it's part of. For example:

    + On collision between Sprite and Family

    • Destroy sprite
  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • you can also give the same object 2-or-more families to have 3-or-more way collision/picking descrimination.

  • thanx, i didn't think of colliding with family, but when i use that i still can't give them each a seperate action

    and i cant use more family's because i cant control what family's will collide

    say that i want each sprite to move to a different location when colliding

    or can i give the one that collides with family a pv and the one in the family a pv?

  • you would control the family one through the family name

    like circle is in family shape

    if circle collides with shape

    move circle to the left

    move shape to the right

    they're still both circles, but you can control them seperately

    by using the object and it's family as separate entities

  • thanx for the help, i thought when i collided with family and i give family somthing to do, the whole family would do it, but its just the one in the collision event

    i also found that with system collision advanced, you can pick on of the two in collison, you could get it to work with that too

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)