How do I create three objects one by one in series ?

0 favourites
  • 3 posts
From the Asset Store
A slots game template designed to be skin-able for mobile
  • I am making an educational game in construct 2. It contains shooting gun containing three colored balls ( basically, those are charges having red, green and blue color). Each colored charge have two charges, +ve and -ve.

    Now, I want those charges to be positioned to spawned (or whatever the simple solution is) one by one and in loop. Let's say I created the red charge then I shoot it. Then, I created the blue charge in place of red charge and then shoot it. Then, I created the green charge in place of blue charge and then shoot it. Now, How do I create or spawn single instance of red charge. I have tried many solutions but didn't work.

    Any solution would be highly appreciated.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Best bet is to use a Global variable for this I think.

    Each time you shoot, add 1 to the variable.

    On the final shot, reset it.

    So your event would be something like:

    On Mouse click & BallNum==1 -- Shoot Blue & add 1 to BallNum

    On Mouse click & BallNum==2 -- Shoot Green & add 1 to BallNum

    On Mouse click & BallNum==3 -- Shoot Red & set BallNum to 1

  • msha91

    Just done a quick Example CAPX file.

    You can get it here: https://1drv.ms/u/s!Au_xHg0ueCl3wQYVTUj0VorZRpMp

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