1、基础介绍;2、基础属性oop
原文地址: http://blog.csdn.net/dingkun520wy/article/details/50923665动画
1、基础介绍spa
FadeTo:从当前透明度变到目标透明度.net
FadeFrom:从给定透明度变到原始透明度code
FadeUpdate:对象
相似于blog
FadeTo,在Update()方法或循环环境中调用。提供每帧改变属性值的环境。不依赖于EasrType.事件
Fade只适用于GUITexture组件,GUIText组件,renderer组件和light组件.
2、基础属性ip
基础属性比较简单直接上代码get
- void Start () {
-
- Hashtable args = new Hashtable();
-
-
- args.Add("alpha", 0);
-
- args.Add("amount", 0);
-
- args.Add("includechildren",true);
-
- args.Add("namedcolorvalue", iTween.NamedValueColor._Color);
-
-
- args.Add("time", 10f);
-
- args.Add("delay", 0.1f);
-
-
- args.Add("easeType", iTween.EaseType.easeInOutExpo);
-
-
-
- args.Add("loopType", iTween.LoopType.pingPong);
-
-
-
- args.Add("onstart", "AnimationStart");
- args.Add("onstartparams", 5.0f);
-
-
- args.Add("onstarttarget", gameObject);
-
-
-
- args.Add("oncomplete", "AnimationEnd");
- args.Add("oncompleteparams", "end");
- args.Add("oncompletetarget", gameObject);
-
-
- args.Add("onupdate", "AnimationUpdate");
- args.Add("onupdatetarget", gameObject);
- args.Add("onupdateparams", true);
-
- iTween.FadeTo(btnBegin, args);
- }
-
-
-
- void AnimationStart(float f)
- {
- Debug.Log("start :" + f);
- }
-
- void AnimationEnd(string f)
- {
- Debug.Log("end : " + f);
-
- }
-
- void AnimationUpdate(bool f)
- {
- Debug.Log("update :" + f);
-
- }