Forum rules - please read before posting.

Animating a Button does not work

Whenever I try to add animations to my menu's it breaks the entire prefab.

I am using the Pause menu in Unity UI Prefab mode to test this:

  • Set the btnResume to Transition: Animation
  • Auto generate the animations
  • Set the scale in the Highlighted animation to something bigger
  • Play the scene and enter the pause menu
  • The animation does not play when you highlight the resume button

Whenever I try to return to Transition: Color Tint it also does not work anymore. It seems the Pause menu is now broken and I have to create a fresh one and try again.

Any help would be appreciated.

Comments

  • Welcome to the community, @GvdBulk.

    When a Button element relies on Unity UI, AC won't interfere with the Button component's Transition properties.

    In following your steps, though, I have found that the Animator component that gets added to the prefab at the "Auto generate the animations" step sometimes doesn't save. I'm not sure if this is an AC issue, as AC shouldn't be involved in this step.

    If this is the case for you, re-open the prefab, locate btnResume and manually attach the Animator component, and assign the Controller that was auto-generated.

    The main thing to watch out for, however, is that Pause menus require any Animators to have their Update Mode set to Unscaled Time - otherwise, playback cannot occur while the game is paused.

  • Thanks for the fast reply @ChrisIceBox !

    You were right about setting the Animators Update Mode to Unscaled Time, which of course makes sense for a pause Menu, but I didn't think of that 😔.

    Thanks a lot, it seems to be working now!
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.