0 Favourites

How do I Jumping

  • Hi,I decided to do my game in construct 2 since a lot of bugs in construct classic,but i dont know how to make jumping animation.

    How to do it,i want my character jumping when spacebar is pressed.

    Also i did character choosing menu,and theres 2 characters-castaway and pirate.

    I set that pirate should be mirrored if left arrow is pressed,but it doesnt work,why ?

    Heres capx

    PS: sorry but this game is going to be made for friends,so it isnt in english.

    h t t p : / / s p e e d y . s h / D j g t u / r a d k e . c a p x (delete spaces to download capx,i havent permissions to put full link ;/)

  • There is "Is on ground" and "Is falling" conditions in "Platformer" behavior.

    Do it like this:

    If (Is NOT on ground)

    {

    if (Is falling) - set animation "falling"

    else - set animation "jumping"

    }

  • Construct 3

    Buy Construct 3

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

    Buy Now Construct 3 users don't see these ads
  • You need to use "Simulate control" action under platform behavior actions for sprite.

    Put it in a keypress event with action simulate control platformer jump.

    I did some minor tweaking on your capx. It should start at menu now by default and goes to the correct layout when you click a character.

    I put the movement behaviors into groups for each character and have it activate/deactivate the other when a different character selected to avoid nasty control bugs (like your lack of pirate control). Both characters mirror and unmirror correctly but the animations need some work .

    https://drive.google.com/open?id=0Bx-ufu2WID53SWRqYmhKS1pMelE (click the download arrow in upper right corner of screen)

    It is far from optimized but it "works" now. One tip though, I see both characters use the same level layout design wise. Why not simply have one layout instead of two and use a spawn sprite event for the chosen character, would be much more efficient.

  • Thanks,works at all.

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