How do I make expanding animaton

0 favourites
  • 6 posts
From the Asset Store
Fully animated twelve sided dice, top down wooden tray and dice throwing cup
  • Hi guys,

    I am really new with Construct 2, I'm currently developing, a simple some kind of "avoid obstacles game" and have manage to make the basic of the game. The game is constructed in a top-down shooter/bullet hell fashion where the player must avoid all the bullets coming. However I am stuck in making some "bomb" animation for the game. I would really appreciate should the construct 2 masters here able to help me to solve on how to make this bomb/expanding animation.

    I'm thinking on making explosion animation coming from the player, as an illustration, the player is a circle, I want to make an explosion which expands from the around the player to fill the whole stage and then that explosion started to disappear. the explosion really is just an expansion of the circle player itself.

    You know it's kind of the animation of bomb power-ups in a top down shooter.

    kind of like this (the outer circle is the bomb)

    [attachment=0:8jsg8lsf][/attachment:8jsg8lsf]

    I probably haven't tried everything and still tinkering with this problem my self, but a help would really be appreciated.

    Thanks guuyss.

  • Something like this?

    Create round sprite at player.x, player.y

    set a variable Xplosion to 1

    system if Xplosion = 1

    • round sprite set width to roundsprite.width+1
    • round sprite set height to roundsprite.height+1
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hai LittleStain!!

    Thank you so much for your help.

    the animation works fine, however there are certain concern/further question that i want to ask.

    • First one is how do i hide the animation at the beginning? since the animation start immediately the game starts and since its expanding in unlimited manner it will definitely reach the stage even if i put it outside the stage.
    • second is, knowing that the animation is expanding throughout the game, will it affect the game say after quite few "bombs" is triggered?
    • the third question is not related to the animation, however regarding score counts. I am currently calculating the score for every tick the game plays. unfortunately, the score will not stop calculating even if the game is over. How do I could make the calculation of the score stops when the player is dead/game over so that we know what is the score of during that play.

    Thank you again for your help, sorry for barraging you with more questions tho

    Thanks a bunch!!

  • You should only trigger the animation when needed by adding conditions and variables..

    You should also make events to stop the animation when needed..

    You should only add to the score if game is not game over, so adding an extra condition would help..

    so if player is alive - add to score

  • Okay, Im gonna try it, wish me luck bro..

  • Hi little stain,

    I hope you're able to help me further, i've managed to make the expanding animation. So as explained, the expanding animation work as a "bomb" which destroy all enemies. I also manage to make the enemies destroyed after it collides with the expanding animation.

    Please note that I make the enemies to appear/spawn randomly from outside of the stage for every 5 seconds by using the system to create object every 5 seconds.

    The problem is, after the bomb destroy the enemies that is on the stage, the enemy (object) is not spawning again. So after the "bomb" destroy the enemies, that is on stage, the instruction which makes the system to create enemy for every 5 seconds wont work since the enemies is not spawning.

    This issue does not occur however if the way the bomb destroy the enemies is not by collision with the enemies. (for example: I make that every time the bomb button is released the enemies is destroyed). The expanding animation runs but the enemies is destroyed at the moment the button is released so the enemies is destroyed not as smooth as I wanted (compare with the enemies is destroyed when it collides with the expanding animation).

    Can you help me with how to solve this?

    Thanks in advance bro. Cheers.

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