コード例 #1
0
    /// <summary>
    /// Start the tweening operation.
    /// </summary>

    static public UGUITweenAlpha Begin(GameObject go, float duration, float alpha)
    {
        UGUITweenAlpha comp = UITweener.Begin <UGUITweenAlpha>(go, duration);

        comp.from = comp.value;
        comp.to   = alpha;

        if (duration <= 0f)
        {
            comp.Sample(1f, true);
            comp.enabled = false;
        }
        return(comp);
    }
コード例 #2
0
 ///只给剧情编辑器使用
 public void CustomBegin()
 {
     UGUITweenAlpha comp = UITweener.Begin <UGUITweenAlpha>(this.gameObject, duration);
 }