How I play the Animation Wall jump in AnimtedSprite?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By VBGames

I create my own fan game MegaMan X
My AnimtedSprite Wall Jump run only the first frame but not all frames it have only 3 frames.

Here is my code:
func Animation_Update():
var RunFrame : int
var JumpFrame : int
var WallSlideFrame : int
var WallJumpFrame : int
var CrouchFrame : int
var DashFrame : int

#Frame
if AnimationType("Run"):
	RunFrame = $AnimatedSprite.get_frame()
if AnimationType("Jump"):
	JumpFrame = $AnimatedSprite.get_frame()
if AnimationType("WallSlide"):
	WallSlideFrame = $AnimatedSprite.get_frame()
if AnimationType("WallJump"):
	WallJumpFrame = $AnimatedSprite.get_frame()
if AnimationType("Crouch"):
	CrouchFrame = $AnimatedSprite.get_frame()
if AnimationType("Dash"):
	DashFrame = $AnimatedSprite.get_frame()
var MoveVector = get_moveVecotr()
if is_on_floor():
	if MoveVector != 0 and not AnimationType("Crouch") and not isDashing:
		PlayAnimation("Run")
		if AnimationType("Run"):
			$AnimatedSprite.frame = RunFrame
		
	elif AnimationType("Jump"):
		if AnimationType("Dash"):
			isDashing = false
		
	elif Input.is_action_pressed("down"):
		PlayAnimation("Crouch")
		if AnimationType("Crouch"):
			$AnimatedSprite.frame = CrouchFrame
	elif Input.is_action_just_released("down"):
		PlayAnimation("Crouch",true)
		if AnimationType("Crouch"):
			$AnimatedSprite.frame = CrouchFrame
	elif isDashing:
		PlayAnimation("Dash")
		if AnimationType("Dash"):
			$AnimatedSprite.frame = DashFrame
		if CurrentDash > 1:
			$AnimatedSprite.frame = 1
	
	elif IsFullCharge:
		$AnimatedSprite.play("FullCharge")
	
	else:
		PlayAnimation("Idle")
else:
	if IsTouchWall():
		PlayAnimation("WallSlide")
		if AnimationType("WallSlide"):
			$AnimatedSprite.frame = WallSlideFrame
		if Input.is_action_just_pressed("JumpKey"):
			PlayAnimation("WallJump")
			if AnimationType("WallJump"):
				$AnimatedSprite.frame = WallJumpFrame
	
	elif velucity.y < 0:
		PlayAnimation("Jump")
		if AnimationType("Jump"):
			$AnimatedSprite.frame = JumpFrame
		if $AnimatedSprite.frame > 3:
			$AnimatedSprite.frame = 3
			
		
		
	elif velucity.y > 0 or (AnimationType("Jump") and velucity.y > 0):
		PlayAnimation("Jump")
		if AnimationType("Jump"):
			$AnimatedSprite.frame = JumpFrame
		if $AnimatedSprite.frame < 4:
			$AnimatedSprite.frame = 4
		if $AnimatedSprite.frame > 4:
			$AnimatedSprite.frame = 4
		
:bust_in_silhouette: Reply From: kareem_farrag

First ckeck var MoveVector = get_moveVecotr()

try to check floor jump and wall jump by adding is_on_floor and is_on_wall

if Input.is_action_just_pressed(“JumpKey”) and is_on_wall :