[SOLVED] 2d character animation bugging

Hello everyone, I have a weird problem and really need an urgent help in the matter. I have been going around it back and forth, googling it but nothing really helped. I have set up a 2D character, put the animations and wrote the scripts for idle, walk, and jump. The problem I’m having is whenever I jump and land on a certain platform in the game, the animation of the character gets stuck on the walking animation (looping forever) and cannot move or jump again.

Here is an example:
alt text

-I tried adding maybe a Physics2D Material to that platform’s collider.
-I tried adding some condtions in if-statements to perhaps limit/restrict animations but didn’t work either.

What I want to do is to make the character jump normally and does not get stuck in place and/or animation loop.

Also for reference, here is both of my used scripts:
Player Movement Script:

Player Attack Script:

The inspector of the game object that character/animation get stuck on:

The Animator of the character:


Your help is much appreciated and would be really grateful!

Never mind, just figured out the problem! Apparently that floating platform was on a different layer from the ground. So I set it to the same layer, and it works better now!