I do I fix animations not working with multiple key functions?

Not favoritedFavorited Favorited 0 favourites
  • 6 posts
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • Hello, I need help with this issue.

    I'm setting up keyboard and Game-Pad controls were the charactor will have a walking animatoin and a running animation. I have it were the left and right keys will make the charactor walk, and than when you hold down a certain button while moving left and right, it will make the charactor run. Everything works on the Keybord but when I set it up on the Game Pad the run animation will only play the first frame so it look like its sliding rather than Running. I was thinking it might be conflicting with the keybord setup but I cant seem to fix it.

    Please somone help (:

  • Did you set up a gamepad or keyboard scenario and disable the other controls when one is in use? What you are describing is when two animations are playing at the same time. If you can't work it out please post the events.

  • Hello, No I do not have any gamepad or keyboard scenario added. I know it's confliting with the Keyboard Walk left and right keys because when I disable that the animation works on the Gamepad controls.

    Here is a picture of the Event and a the link to the file if needed.

    drive.google.com/file/d/1iraZkWNtQkgJ0DdiOwiV4Ax03EilcAMR/view

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Your events 27-30 are constantly changing the animation between Cwalk and Run.

    Here is how you can fix it:

    And do the same for D-pad left events.

  • Hello, Thank you so much :)

    Are you able to send me the event sheet file you did? I must be doing somthing wrong because I followed your instructions but I cant seem to get it working correctly.

    Sorry still a lttle new at this.

  • Paste this into your event sheet:

    {"is-c3-clipboard-data":true,"type":"events","items":[{"eventType":"block","conditions":[{"id":"is-button-down","objectClass":"Gamepad","parameters":{"gamepad":"0","button":"d-pad-left"}}],"actions":[{"id":"simulate-control","objectClass":"Player","behaviorType":"Platform","parameters":{"control":"left"}}],"children":[{"eventType":"block","conditions":[{"id":"is-button-down","objectClass":"Gamepad","parameters":{"gamepad":"0","button":"button-x"}}],"actions":[{"id":"set-animation","objectClass":"Player","parameters":{"animation":"\"Run\"","from":"current-frame"}}]},{"eventType":"block","conditions":[{"id":"else","objectClass":"System"}],"actions":[{"id":"set-animation","objectClass":"Player","parameters":{"animation":"\"Cwalk\"","from":"current-frame"}}]}]},{"eventType":"block","conditions":[{"id":"is-button-down","objectClass":"Gamepad","parameters":{"gamepad":"0","button":"d-pad-right"}}],"actions":[{"id":"simulate-control","objectClass":"Player","behaviorType":"Platform","parameters":{"control":"right"}}],"children":[{"eventType":"block","conditions":[{"id":"is-button-down","objectClass":"Gamepad","parameters":{"gamepad":"0","button":"button-x"}}],"actions":[{"id":"set-animation","objectClass":"Player","parameters":{"animation":"\"Run\"","from":"current-frame"}}]},{"eventType":"block","conditions":[{"id":"else","objectClass":"System"}],"actions":[{"id":"set-animation","objectClass":"Player","parameters":{"animation":"\"Cwalk\"","from":"current-frame"}}]}]}]}
    
    
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)