Discuss Scratch

LionHeart70
Scratcher
1000+ posts

Idle/walk animations

So, I kinda want to figure out how to make there be an idle animation and a walk animation in the game I'm working on. When the character hasn't moved for a short time, it'll do an idle animation. If it does move, it'll have a walk animation.
How can I make it so there is an idle animation and a walk animation without it glitching?
powercon5
Scratcher
1000+ posts

Idle/walk animations

What scripts are you using. Could you share the project?
LionHeart70
Scratcher
1000+ posts

Idle/walk animations

powercon5 wrote:

What scripts are you using. Could you share the project?
I can't share the project because it's something that's still being heavily worked on and will take a long time to finish, and there's more to it.
I also have no scripts for it because I need help with finding out how to make the scripts for it.
asivi
Scratcher
1000+ posts

Idle/walk animations

Because you asked involves visual stuff you need to show it, also try to program it firstly, this is not a collab or request forum…
LionHeart70
Scratcher
1000+ posts

Idle/walk animations

asivi wrote:

Because you asked involves visual stuff you need to show it, also try to program it firstly, this is not a collab or request forum…
Okay, I think I may've gotten it, I just need to know if there's something I can do that's kinda like the equivalent of “no keys pressed”.
powercon5
Scratcher
1000+ posts

Idle/walk animations

LionHeart70 wrote:

asivi wrote:

Because you asked involves visual stuff you need to show it, also try to program it firstly, this is not a collab or request forum…
Okay, I think I may've gotten it, I just need to know if there's something I can do that's kinda like the equivalent of “no keys pressed”.
So if no keys are pressed or if specific keys are not pressed.
This?
notkeyanypressed?
LionHeart70
Scratcher
1000+ posts

Idle/walk animations

powercon5 wrote:

LionHeart70 wrote:

asivi wrote:

Because you asked involves visual stuff you need to show it, also try to program it firstly, this is not a collab or request forum…
Okay, I think I may've gotten it, I just need to know if there's something I can do that's kinda like the equivalent of “no keys pressed”.
So if no keys are pressed or if specific keys are not pressed.
This?
notkeyanypressed?
Yeah, that sounds good. The keys I want to use for the walking is the arrow keys (up, down, left, and right), the character will have a different walk cycle based on what direction it's going in. For example, if going right, it'll have its normal walk cycle from the right side view, if it's going left, it'll have its normal walk cycle except flipped (left side view), if going up, it'll show the walk cycle from the back view, and if it's going down, it'll show the walk cycle from the front view. The character also has an idle animation if it hasn't been moving for any time between 0 seconds and 10 seconds. (This is prone to change as the game is still being made!)
gtoal
Scratcher
1000+ posts

Idle/walk animations

you need to make the walk cycle have a starting sequence and an ending sequence where it transitions from walking to standing. the first and last frames should also be the same as the start and end of the idle sequence. that way you always have a smooth transition between the two modes.

so:

1) from standing to walking

2) walking loop

3) from walking to standing

4) standing loop

then just be careful to transition at the end of each loop rather than the instant the key is pressed or released.
LionHeart70
Scratcher
1000+ posts

Idle/walk animations

gtoal wrote:

you need to make the walk cycle have a starting sequence and an ending sequence where it transitions from walking to standing. the first and last frames should also be the same as the start and end of the idle sequence. that way you always have a smooth transition between the two modes.

so:

1) from standing to walking

2) walking loop

3) from walking to standing

4) standing loop

then just be careful to transition at the end of each loop rather than the instant the key is pressed or released.
Thanks
SEGAdreamcast1999
Scratcher
20 posts

Idle/walk animations


deck26
Scratcher
1000+ posts

Idle/walk animations

SEGAdreamcast1999 wrote:


Please don't spam or necropost.

Powered by DjangoBB