Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | CakeLover |
I’m trying to create my own plugin and I need to figure out which AnimationPlayer
node is currently shown in the bottom Animation panel
and please do not suggest I use get_selection()
because even if I select multiple (or none ) AnimationPlayer
node(s), only one is show on the Animation Panel
so far my approach has been to try finding the node to the Animation panel using get_editor_interface()
and then maybe viewing it’s properties?
current animation .
Did I misunderstand the question?
ramazan | 2022-02-01 20:50
I’m sorry I don’t follow what do u mean by “current animation .”?
CakeLover | 2022-02-01 20:52
get_current_animation()
AnimationPlayer — Godot Engine (stable) documentation in English
ramazan | 2022-02-01 20:57
the docs haven’t specified how to use get_current_animation()
could u explain?
CakeLover | 2022-02-01 21:04
print (current_animation)
Sorry, I’m not at the computer.
ramazan | 2022-02-01 21:07
how am I suppose to use that here?
tool
extends EditorPlugin
func _enter_tree():
print(get_current_animation());
CakeLover | 2022-02-01 21:09
print (current_animation)
Delete get and “()”
ramazan | 2022-02-01 21:11
how is that suppose to work?
it’s a property you can’t just print it out without having the AnimationPlayer
node itself
CakeLover | 2022-02-01 21:14
Sorry, I’m not at the computer.
ramazan | 2022-02-01 21:16