Exemple #1
0
    void Awake()
    {
        mPositionLerpTo = new LerpToVector2(this, mPositionLerpFactor);
        mRotationLerpTo = new LerpToVector2(this, mRotationLerpFactor)
        {
            Continuous = true
        };

        mRotationLerpTo.InitLerp(-mRect.up, SetFacingDirection);
    }
Exemple #2
0
    private void Awake()
    {
        mCurrentLerps = new Dictionary <RectTransform, LerpToVector2>();

        foreach (RectTransform transform in mLerpTransforms)
        {
            mCurrentLerps[transform] = new LerpToVector2(this, mLerpFactor)
            {
                Epsilon = mLerpEpsilon,
            };
        }
    }