COMBO attacks moving animation

0 favourites
  • 6 posts
From the Asset Store
Combo
$10 USD
Button Combinations like in fightings, supports both keyboard and gamepads
  • hey ,

    I am working now on a metroidvania sidescroller and having hard time with combo system. While I managed to get combo attack with different animations using timer, I don't know how to approach moving player's object to match with its animations' object.

    Will try to explain this more clear:

    For example I want my player to move forward while slashing with the sword ( with each attack it moves 1 step forward) , so I create the animation in wich player moves as he attacks, but what would be the logic to implement this ingame ? Was thinking to move player X pixels in the direction I need at but that would require to calculate the distante in the animation through trial and error a lot of times, and if it doesnt match it looks awkward and would be crazy hard to do this way when having air combos and so on. Any thoughts on this ?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • bump

  • This is just off the cuff and may not work with your events, but someone else might be able to correct me or provide a better way. You could try adding an instance variable and calling it a STATE - text - . So as the player is walking SET the STATE to "WALKING" (with quotes), if Attacking, Set the STATE to "ATTACKING."

    In your events you could try (Press (whatever your attack key is) add condition - player's STATE = Walking, (or that last part might need to be made in to a sub-event) and then add action attack animation.

    The other thing you could try is create an event:

    PLAYER IS MOVING (The platform icon that is moving)

    Button is pressed > Add action>Play Attack animation.

    I'm learning myself, but people here have been pretty helpful, so if this doesn't work, I'm sure someone will figure it out. Good Luck.

  • hey ,

    I am working now on a metroidvania sidescroller and having hard time with combo system. While I managed to get combo attack with different animations using timer, I don't know how to approach moving player's object to match with its animations' object.

    Will try to explain this more clear:

    For example I want my player to move forward while slashing with the sword ( with each attack it moves 1 step forward) , so I create the animation in wich player moves as he attacks, but what would be the logic to implement this ingame ? Was thinking to move player X pixels in the direction I need at but that would require to calculate the distante in the animation through trial and error a lot of times, and if it doesnt match it looks awkward and would be crazy hard to do this way when having air combos and so on. Any thoughts on this ?

    Why not have 2 sprites (one for the legs and one for the body), animate the body for attack and idle and the legs for running and idle, pin them together and when the player presses "space" for example, body- play animation attack; legs- play animation running; legs/body (depending on which you pinned to which)- move at angle (0- right; 90- down; -90- up; 180- left) (Nr of pixels)

    Like this you can have the player running (without attacking) without making another animation, and it's easier to make new attacks.

    Let me know if it works!

  • hey, as soon as will get home will try both things, although the project is put on shelf for now. Thank you both!

    TRMG - I can't reply to your pm ( I dont have those 500 points required). I'm on a new machine and don't have access to that project but from what I can remember I found how to do that on the forum in a topic with an example of shoot 'em up game. Maybe you could try and search, should be an easy find, I can't right now.

  • Combos like this?

    You should store the attack command before executing it and trigger it ready, also, the attack condition should wait until the animation is finished.

    This sample and template will be on sale soon. I get delayed with it because some milestones are making me rethink the entire event sheet to make it reach 50 events. Unfortunately it's currently using more than 100 and users of the free version will be unable to use it on their projects.

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