godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.12k stars 21.18k forks source link

Cant Use State Machine with AnimatedSprite node #29860

Closed Duroxxigar closed 4 years ago

Duroxxigar commented 5 years ago

Godot version: 3.2

Issue description: Cannot use built-in state machine with the AnimatedSprite node. With the changes coming to the AnimatedSprite node in regards to handling spritesheets; we should be able to use the built-in state machine with the AnimatedSprite node.

Current workflow with spritesheets is to have a Sprite node and AnimationPlayer, with the AnimationPlayer cycling through the Frame property in the Sprite node. Reduz has expressed the intent to remove this workflow by getting rid of the Frame property in the Sprite node. By doing this, we will only be able to use the AnimatedSprite node for spritesheets. However, the built-in state machine requires an AnimationPlayer in order to grab the animations from. The AnimatedSprite node handles the animations in this context.

Without a change to accommodate this change in workflow, we will end up having to use an AnimatedSprite and AnimationPlayer node in order to use the built-in state machine. Effectively recreating the current workflow anyway.

I would think it would make sense for the built-in state machine to be able to select the AnimatedSprite node and automatically pull in the animations that are saved in that node.

(Somewhat similar to #29403 )

mhilbrunner commented 4 years ago

Feature and improvement proposals for the Godot Engine are now being discussed and reviewed in a dedicated Godot Improvement Proposals (GIP) (godotengine/godot-proposals) issue tracker. The GIP tracker has a detailed issue template designed so that proposals include all the relevant information to start a productive discussion and help the community assess the validity of the proposal for the engine.

The main (godotengine/godot) tracker is now solely dedicated to bug reports and Pull Requests, enabling contributors to have a better focus on bug fixing work. Therefore, we are now closing all older feature proposals on the main issue tracker.

If you are interested in this feature proposal, please open a new proposal on the GIP tracker following the given issue template (after checking that it doesn't exist already). Be sure to reference this closed issue if it includes any relevant discussion (which you are also encouraged to summarize in the new proposal). Thanks in advance!