Godot Version
v4.5.stable.official [876b29033]
Question
I updated Godot recently, and animations stopped working the way I expected them to. I tried to understand what I’m doing wrong, set up a test scene, but still found no solution.
The test setup is one AnimationPlayer and one AnimationTree with Tree Root AnimationBlendSpace1D. I set Blend Position by reading input directly:
func _unhandled_input(event: InputEvent) -> void:
if event.is_action_pressed("left"):
set("parameters/blend_position", -1.0)
elif event.is_action_pressed("right"):
set("parameters/blend_position", 1.0)
There are two points in the BlendSpace, connected to the animations in the AnimationPlayer. Both animations have one track that calls this function with arguments “left” and “right”:
func print_stuff(stuff: String):
print(stuff)
I expected to see “left” or “right” printed when I press the corresponding buttons (the actions are set up in the settings and work), but this did not happen. When running the game I can see that the Blend Position changes to the correct values, but Current Animation in the Animation Player never changes, and the function never gets triggered.
I’m very confused by this. I had a very similar setup (but with actual animations) working in Godot 4.2.2, but it stopped functioning after the update. I can’t understand what I’m missing, please help ![]()