• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Windows Help In making Advanced Transition From Walk To Run Animation

K

khaledzaw

Guest
Hello,

Usually when implementing a walk animation people make it so when a player presses the run command while holding for example the Shift key the character walks.

Some games implement a really neat feature where if you lightly press the run key the character walks, and when using a controller just lightly pushing the joystick will result in the character walking too.
I want to implement this feature because it gives a polished representation of the mechanics of the project and I don't know how so any help would be appreciated :)

Thanks.
 

FoxyOfJungle

Kazan Games
Basically the player will have an acceleration when walking, so the player's animation speed will be based on that movement speed, which will be increased with this acceleration. Remembering that the keyboard does not support "lightly press", only joystick (the lever).
 
K

khaledzaw

Guest
Basically the player will have an acceleration when walking, so the player's animation speed will be based on that movement speed, which will be increased with this acceleration. Remembering that the keyboard does not support "lightly press", only joystick (the lever).
Thanks!
Shame really.
Think that they might add it in a future release?
 

FoxyOfJungle

Kazan Games
Thanks!
Shame really.
Think that they might add it in a future release?
Why a shame? You can do this smoothly with the current GMS 2.


Think that they might add it in a future release?
What specifically? Press lightly? I wanted to mention that the keyboard input only supports 1 and 0 (true and false), but that's no problem. The only thing you are going to do is to program in a way in which the player's animation speed is based on the player's speed, to be realistic he will have an acceleration and deceleration.

Take a look at this topic:
 
Last edited:
K

khaledzaw

Guest
Why a shame? You can do this smoothly with the current GMS 2.




What specifically? Press lightly? I wanted to mention that the keyboard input only supports 1 and 0 (true and false), but that's no problem. The only thing you are going to do is to program in a way in which the player's animation speed is based on the player's speed, to be realistic he will have an acceleration and deceleration.
Only problem is that the project is a platformer so and the main character isn't a car so acceleration isn't so much of an option :(
EDIT: Apparently Cave Story did this and it worked wonderfully so thanks for the idea :D
 

FoxyOfJungle

Kazan Games
Only problem is that the project is a platformer so and the main character isn't a car so acceleration isn't so much of an option :(
It doesn't have to be a car, see Super Mario World games (SNES era), he accelerates when walking, that's acceleration, take a look at the topic I showed above.



Notice that his speed is based on the speed that he moves.
 
Last edited:
Top