Beispiel #1
0
    static public TweenPositionY Begin(GameObject go, float duration, Vector3 pos, float height)
    {
        TweenPositionY comp = UITweener.Begin <TweenPositionY>(go, duration);

        comp.from            = comp.value;
        comp.to              = pos;
        comp.m_heightCurve   = CreateMoveCuve(1);
        comp.style           = Style.Once;
        comp.ignoreTimeScale = false;
        if (duration <= 0f)
        {
            comp.Sample(1f, true);
            comp.enabled = false;
        }
        return(comp);
    }