Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Required feature for advanced animations- AnimationGraph Customizing #225

Open
xx1adfasd opened this issue Aug 10, 2024 · 2 comments
Open

Comments

@xx1adfasd
Copy link

xx1adfasd commented Aug 10, 2024

In bevy 0.14, bevy added a "AnimationGraph", it means that we can blend different animation all together.

But in the current code of Blenvy, the graph is handled inside blenvy and it's not smart. The code just add them all to the root.

However, consider a 3rd person shooting game, one of the animation solutions is to have two animations, the walking one and the "holding gun" one. The walking one controls the lower body, and the "holding gun" one controls the upper body. In this case, not all the animations are all in the root graph. The graph just branched and is being played simultaneously.

I wonder how should we deal with this situation.

I suggest that there should be an option for the user to provide a "custom graph configuring function"?

@xx1adfasd xx1adfasd changed the title Required feature for advanced animations Required feature for advanced animations- AnimationGraph Customizing Aug 10, 2024
@kaosat-dev
Copy link
Owner

Hi !
I'll be honest, I still have trouble understanding how Bevy injects & deals with animation data (& AnimationGraphs) by default, and my animation knowledge in general is lacking.
In your example, would the two animations not be on different objects in the first place ?

I have no idea how a "custom graph configuring function" would work, as the boilerplate for animations in Bevy is already quite horrible , but if you can provide more details, I am more than willing to add/change things.

@xx1adfasd
Copy link
Author

xx1adfasd commented Aug 11, 2024

In my example, the two animations are all on the same object in the first place. (It's always on the same object, and it's not related to "cross-object" thing)

I think by running and learning from the official bevy example
https://github.com/bevyengine/bevy/blob/main/examples/animation/animation_graph.rs

online preview:
https://bevyengine.org/examples/animation/animation-graph/

you will get the idea on how AnimationGraph works. The example is great, as you can see the graph directly on the screen and adjust it.

Yeah I think I can help on this topic. But right now I'm going to have something to eat. See you later on github.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants