コード例 #1
0
        public RectTransformAnimation(RectTransform rectTransformToAnimate, RectTransform destinationRectTransform, RectTransform originRectTransform, float duration = 1f, Curve curve = Curve.EaseInOut)
        {
            this.rectTransformToAnimate   = rectTransformToAnimate;
            this.originRectTransform      = originRectTransform;
            this.destinationRectTransform = destinationRectTransform;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
        }
コード例 #2
0
        public TransformAnimation(Transform transformToAnimate, Transform destination, Transform origin, float duration = 1f, Curve curve = Curve.EaseInOut)
        {
            this.transformToAnimate   = transformToAnimate;
            this.originTransform      = origin;
            this.destinationTransform = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
        }
コード例 #3
0
        public Vector2Animation(Vector2 vector2ToAnimate, Vector2 destination, Vector2 origin, float duration = 1f, Curve curve = Curve.EaseInOut, WrapMode wrapMode = WrapMode.Once)
        {
            this.vector2ToAnimate   = vector2ToAnimate;
            this.originVector2      = origin;
            this.destinationVector2 = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
            this.wrapMode = wrapMode;
        }
コード例 #4
0
        public ColorAnimation(Color colorToAnimate, Color destination, Color origin, float duration = 1f, Curve curve = Curve.EaseInOut, WrapMode wrapMode = WrapMode.Once)
        {
            this.colorToAnimate   = colorToAnimate;
            this.originColor      = origin;
            this.destinationColor = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
            this.wrapMode = wrapMode;
        }
コード例 #5
0
        public CameraAnimation(Camera cameraToAnimate, Camera destination, Camera origin, float duration = 1f, Curve curve = Curve.EaseInOut, WrapMode wrapMode = WrapMode.Once)
        {
            this.cameraToAnimate   = cameraToAnimate;
            this.originCamera      = origin;
            this.destinationCamera = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
            this.wrapMode = wrapMode;
        }
コード例 #6
0
        public FloatAnimation(float floatToAnimate, float destination, float origin, float duration = 1f, Curve curve = Curve.EaseInOut, WrapMode wrapMode = WrapMode.Once)
        {
            this.floatToAnimate   = floatToAnimate;
            this.originFloat      = origin;
            this.destinationFloat = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
            this.wrapMode = wrapMode;
        }
コード例 #7
0
        public IntAnimation(int intToAnimate, int destination, int origin, float duration = 1f, Curve curve = Curve.EaseInOut, WrapMode wrapMode = WrapMode.Once)
        {
            this.intToAnimate   = intToAnimate;
            this.originInt      = origin;
            this.destinationInt = destination;


            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
            this.wrapMode = wrapMode;
        }
コード例 #8
0
        public TransformAnimation(Transform transformToAnimate, Transform destination, Transform origin, float duration = 1f, Curve curve = Curve.EaseInOut, bool move = true, bool rotate = true, bool scale = true)
        {
            this.transformToAnimate   = transformToAnimate;
            this.originTransform      = origin;
            this.destinationTransform = destination;

            this.move   = move;
            this.rotate = rotate;
            this.scale  = scale;

            this.duration = duration;
            this.curve    = SimpleAnimation.GetCurve(curve);
        }