Godot Version
Godot v.4.2
Question
Hello I am new to Godot, and have a question I haven’t been able to find the answers to. I am using the AnimatedSprite3D node to make a character move in simple 3d space. However, when I move the character, on the first frame of the animation plays when I walk in any of the four(ish) directions. i followed the documentation for the 2d animated sprite because to me it was saying is the same for 3d. I know it is somewhat recognizing the sprite3d node because when I comment out my method for changing the animation I don’t even get the first frame and its a static sprite for all directions.
Here is my code in the character body 3d node script, with the animatedsprite3d as its child, in a func _process(delta)
# Move left
if Input.is_action_pressed("move_left"):
_animated_sprite.play("WalkLeft")
else:
_animated_sprite.stop()
# Move Right
if Input.is_action_pressed("move_right"):
_animated_sprite.play("WalkRight")
else:
_animated_sprite.stop()
# Move Down
if Input.is_action_pressed("move_forward"):
_animated_sprite.play("WalkUp")
else:
_animated_sprite.stop()
# Move Up
if Input.is_action_pressed("move_backward"):
_animated_sprite.play("WalkDown")
else:
_animated_sprite.stop()