How do I pick a random object from a Family to instance?

  • I am building a very basic ball physics game and have grouped various ball types together in a family. What I would like to do is at random intervals replace the family member currently on stage with a randomly selected member.

    I had a look into arrays but they just store strings or integers, not object references. However surely a family could be seen as another type of array, are the members given indexes that I can call against?

    OT is it possible to speed up the physics simulation over time to increase the games difficulty?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Got it, was going about things in the wrong way, I basically took all my members out of the family and setup individual animation frames on the ball, then at random intervals I can change the animation frame for a different one. Dead easy.

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