Forum rules - please read before posting.

Troubles with Character: Animate - Set Standard

edited April 2021 in Technical Q&A

Hi everyone! I'm using Unity 2020.3.1 and AC 1.73.3 and I'm using Sprites Unity to animate.

I've been using Set Standard to swap out a character's idle animations during a conversation (because their standard idle animation is them being asleep). This has been working pretty well, but the problem lies in trying to Set Standard back to the original idle animation. It changes the Idle animation name in the inspector, but the sprite stays frozen on whatever animation it was doing before the set standard. I was testing this out and can post some examples of the action lists I've tried to use.

Is there something I'm missing? Is there a more effective way to accomplish what I'm trying? Any help would be greatly appreciated!

Comments

  • The Action's "Set Standard" command only affects the names of your standard animations - as you're seeing with the name changes in the Inspector.

    It doesn't otherwise have an effect on which animation is currently being played, though - so if you're currently playing e.g. a custom animation, it won't stop that animation from playing.

    Which animation is the sprite currently frozen at? If no custom animation is playing, the character should revert to their standard animations (idle/talk/walk etc) provided that those animations exist. Have a look in your Console - it should report if it's attempting to play an animation that isn't present in your Controller.

    Try also using another Character: Animate Action with the "Reset To Idle" command - if a custom animation is being played, that'll cancel it.

    By all means, share some images of what you've got - best to see the Actions, character Inspector, and Animator controller, to get the full picture.

    It's also worth mentioning that an alternative to Sprites Unity is Sprites Unity Complex - which relies on controlling animation by Animator Parameter values. An included example can be found with the 2D Demo's Brain2D_SpritesUnityComplex prefab. Though, simply changing the character's idle animation shouldn't strictly require the use of this option.

  • Resetting to Idle solved seems to have solved my issues, thank you!

    I just have one more side question. I read through the section in the manual on Sprites Unity Complex and tried out the complex demo version of Brain and I want to use it but I'm still just a little confused on a few things. Are the mecanim parameters assigned values through scripting? Is there a tutorial that goes over it?

  • Mecanim parameter values are assigned automatically - provided that you inform AC which ones it can control.

    This is done by entering their names into the character's Inspector - for example, setting the "Move speed float" field to the Float parameter that will be used to control the Idle/Walk animation transition.

    This is the same approach used for 3D characters, with the added step of having a parameter that accounts for the character's facing direction - but the Brain prefab variant should demonstrate how this works.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.