This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
0 votes

Hello i am trying to do a very simple Animation Tree Blend of just Idle and Run but this is not working correctly i am looking at the godot docs and i am using the following:

anim_tree["parameters/Seek/seek_position"] = 0.0

The error i get is this: Invalid call. Nonexistent function 'set' in base 'Nil'

Im not sure what to do to attempt to fix this im still new to Animation Trees.

Godot version 3.3
in Engine by (41 points)

I think that means that anim_tree is null. What's the line where you assign a value to it?

1 Answer

0 votes

I know this is very old, but that simply isn't how you set the parameters on an AnimationTree. The correct way to do it would be:

anim_tree.set("parameters/Seek/seek_position", 0.0)

In general, you have to use .get() and .set() with an AnimationTree to get or set parameter values.

by (116 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.