How do I make each sprite have its own behavior?

0 favourites
  • 2 posts
From the Asset Store
Pixel Sprites ala ReactorCore - Builder Hardware - Large pack of sprites!
  • Hello everyone.

    Thanks for reading this message. I seek your help because I can't get the result I'm looking for.

    I have a game where it's a wall full of balloons (animation 1), every time you touch a balloon it explodes (animation 2) and you earn points.

    What I would like to achieve is that every certain amount of time the balloons would inflate again (animation 1) but individually, that is, if I popped the balloon one at x y time and the second at another time, each one would return its main animation.

    Here are some screenshots and the idea that I have been doing so far

    My sprite has a Instance Variable called TimeToChange

    When you touch the sprite the Instance Value set value to 0

    Then I check in random time (1 to 3 seconds) anf If the condition then change the animation.

    But with this, the inflate again at the same time.

    If anyone can help me I'll be so grateful.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I would suggest using Timer behavior. You can run a timer for each balloon, for example:

    On Tap Balloon : Balloon start "reinflate" Timer for random(3,5) seconds
    
    Balloon On "Reinflate" timer : Start "reinflate" animation
    
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)