Unity2017.1 official Ugui document translation--animation integration

Source: Internet
Author: User

Animation Integration Animation Integration

Animation allows for each transition between control states to be fully animated using Unity ' s Animation system. The the most powerful of the transition modes due the the number of the properties that can be animated simultaneously.

Animate with Unity's animation, allowing transitions between individual control states. Because of the number of animated features that can be used simultaneously (many), this is the most powerful conversion mode (in addition to the animation mode, there are several other animation conversion modes, see the Transition field)

The Animation transition mode, an Animator Component needs to is attached to the controller element. This can is done automatically by clicking "Auto Generate Animation". This also generates a Animator Controller with states already set up, which would need to be saved.

The new Animator controller is a ready-to-use straight away. Unlike most Animator Controllers, this controller also stores the animations for the controller ' s transitions and these CA n be customised, if desired.

In order to use the animation conversion mode, a animator component needs to be mounted on the control element. This can be automatically generated by clicking on "Auto Generate Animation", which will generate a animator Controller that is already set up and save it.

This new animation controller can be used immediately. Unlike most animation controllers, this controller saves the conversion animations of the control elements, which can be customized if you wish.

For example, if-a Button element with an Animator controller attached are selected, the animations for each of the Button ' s States can edited by opening the Animation window (window>animation).

There is a Animation clip pop-up menu to select the desired clip. Choose from "Normal", "highlighted", "Pressed" and "Disabled".

For example, if an element that is hung on an animation controller is selected, the animation window can be edited in the Window->animation menu to edit the animation of the button's individual states

Here's an animated clip pop-up menu that lets you choose the clip you want, from normal, Highlight, Pressed, disabled

The Normal state was set by the values of on button element itself and can being left empty. On all other states, the most common configuration was a single keyframe at the start of the timeline. The transition animation between States would be handled by the Animator.

The normal state is the same as the button set (\ position, rotation, scaling, etc., meaning this button is long what kind of normal state is what kind), this animation can not do, let it empty. For other states, the most common configuration is that there is a keyframe at the first frame of the timeline. As for the animation between the switch is handled by the animator (like the flash tween animation, should be automatic difference calculation of the bar).

As an example, the width of the "button in the" highlighted state could is changed by selecting the highlighted state from T He Animation Clip pop up menu and with the playhead at the start of the time line:

    • Select The Record Button
    • The width of the Button in the Inspector
    • Exit the record mode.

For example, you can change the width of the button in the Hightlight state by selecting the highlight state in the Animation Clip Selection window and then to the starting position of the timeline:

    • Press the Record button
    • To modify the width of a button in Inspector
    • Exit recording mode

Change-to-play mode to see how the button grows when highlighted.

Switch to play mode to see how the button behaves in highlighted mode.

Any number of properties can has their parameters set in this one keyframe.

In this keyframe, any number of attributes can be set

Several buttons can share the same behaviour by sharing Animator Controllers.

Several buttons can share the animation controller to achieve the same behavior

The UI Animation transition mode is not a compatible with Unity ' s legacy Animation system. You should only use the AnimatorComponent.

The animation switching mode of the UI is incompatible with the old animation system of unity. You can only use the animator component

Unity2017.1 official Ugui document translation--animation integration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.