Anim State Graph Closed Beta - Feedback here!

are there any errors in the browser developed console?

here the screen when I click the button “open graph editor”:

Hi @dinof, thanks for reporting this. I wasn’t able to reproduce it with the steps you set out. Would it be possible to add me to the project that has the issue?

My PlayCanvas username is ellthompson

I understood! problem comes when you remove the flag from loop option at “initial state”
If I leave loop checked at “initial state”, problem doesn’t comes anymore. I can instead uncheck loop option for all other states without problems and witout errors in console.

I made a pubblic project: https://playcanvas.com/project/784703/overview/dino-bugtest--anim-graph-editor

1 - open: test scenes

2 - go to folder : anim graph editor

3 - you will find two graphs, only one can be opened (the one with loop checked at first state)

@redka @dinof @Fus_ion A fix has been released to production which should address the issues/crashes you were experiencing when editing state attributes in the graph editor.

4 Likes

Hello,

As I understood from “Tutorial Anim Blending” its impossible to prepare movements of entities through “Anim State Graph”, am I right?

What do you mean by ‘movements of entities’?

For example I want to prepare simple sliding door system which should be controled by a 2d button, so I need to prepare conditions of how sliding doors should open: speed of opening, length of movement of each door etc., so all this things I need to write in JS code which will be added to an entity in main editor of playcanvas, did I understand correctly?

It sounds like you were thinking this would be an animation timeline? The state graph is more of a logic state machine that’s gated by parameters. It doesn’t actually do the animation.

You can attach animation to each state which plays when the graph enters that state.

Is it possible to find some similar samples with doors here?

Code would generally be the simplest way to approach this as it’s a simple linear movement. Please start a new thread if you need further help on this.

I just had a quick look at the anim state graph, it looks to have all the functionality required to transition between animations.

I was going to look into it as a way to handle UI transitions, but of course there is no way currently to create animations for UI ( or other ) elements, they need to be imported from an external package ( which isn’t possible for the built-in components ).

Are you planning a way to create animations within PlayCanvas ( a keyframing tool )?

Unfortunately, not on the short term roadmap. I think the next major bit of Editor work with be to standardise the Editor API so that plugins and extensions can be made.

That said, we did have some brief discussions about the state editor being able to do more than drive GLB animations but again, not in the short term. Would be great to have it be able to call tweens for example.

1 Like

If I create an enitiy with the new anim component and I add a child entity as the root bone, the root bone is missing when I copy the entity or create a template of it. I assume the root bone has to be my model?

image

For some reason, the animation will also not start if the root bone is a child entity. If the root bone is the entity with the anim component on it, the animation will start correctly.

An error on the bottom and an error in the console:

I now get stuck with this error:

This error arises when I add a new (third) state:

When I attach another animation to this state the error stays.
If I remove the animation (so only an emtpy state) the error is gone.

Also when I add an empty state without any transition the animation stops working.

Hmm… It might be because you are using JSON for animation. @Elliott can we use JSON with the state graph or just GLBs?

nope, only glb animations are supported.

1 Like

Yes, that was the problem indeed. I re-imported all animations as gbl and that fixes the last reported error. Thanks!