godotengine / godotengine/godot-docs
Proposal for tutorial on AnimationPlayer custom signal tracks
- Dominant language
- reStructuredText
- Stars
- 5.7k
- Forks
- 3.8k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 25
Description
**Your Godot version:**
4.0.1
**Issue description:**
I found myself in partial need of a similar solution to this proposal:
https://github.com/godotengine/godot-proposals/issues/1594
However, my needs were more restrained. I only needed a signal to fire at a specific moments of an animation so that eg. my `damage()` function would trigger on the `hit` frame of the animation.
However, instead of creating a track and keyframe for every function that need to call in that moment of the animation (since there may be an arbitrary `n` number of events that should trigger) I came up with a quick workaround that is practical in multiple ways compared to adding a new `signal track` type to the animation player, which was my first instinct.
in summary, adding a signal and signal emitter function to the animation player via a script that can be called with a `call method` track is a satisfactory, useful, but not altogether completely obvious solution.
I think the technique may be simple enough to be stumbled upon by someone familiar enough with Godot to connect the dots, but a tutorial would go a long way towards revealing how advanced animation really can be in Godot, especially for showcasing event triggering with precise timing.
I'm already working on a PR, but just like with Godot-Proposals I thought it best to see how the community feels about this idea. is it non-obvious enough to merit it's own tutorial in the documentation?
Otherwise I might just make a YouTube tutorial (although I still will in all likelihood).
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.