Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Animated UI Image driven by Animator component?

Discussion in 'UGUI & TextMesh Pro' started by MRKane, Mar 28, 2017.

  1. MRKane

    MRKane

    Joined:
    Oct 4, 2012
    Posts:
    54
    Hello all!

    Please excuse me posting here if I've missed something obvious, but it's the end of an 11 hour day and this issue has been vexing me the entire time!

    Here's the plan:
    Our artist has invented a fantastic UI design for the vehicle the player is interacting with. It's got a fancy animation for when it's airborne, when it's grounded, when it takes off, when it lands, when the player begins interacting with it, and it closes away when the player is finished interacting with it - and that's just the backing not considering the text it's display! So suffice to say it's pretty cool.

    And the method (hopefully):
    I've got quite a collection of png sequences to use for the different animations, and while I can attach one to an animation and drive it on loop on a UI Image, I'd like to know if it's possible to drive this as one would a sprite character using Unities Animatior engine, where the different animation sequences are setup inside, with it echoing what the vehicle is doing (so using the same state switches).

    Any help is greatly appreciated, we're fast approaching crunch so baby steps when explaining how to do this (if possible) will be appreciated by all the tired crew here in the office!

    Thanks so much everyone!