Ejemplo n.º 1
0
    //移動
    private void  MoveMent()
    {
        //移動開始
        if (IsMoveStart)
        {
            DirectionTimer += Time.deltaTime;

            //時間内は移動
            if (DirectionTimer < clothing.GetMoveTime())
            {
                this.transform.localPosition = new Vector3(Easing.OutSine(DirectionTimer, clothing.GetMoveTime(), EndPosition.x, MoveStartPosition.x)
                                                           , 0.0f, 0.0f);
            }
            else
            {
                this.transform.localPosition = new Vector3(EndPosition.x, 0.0f, 0.0f);
                IsMoveStart    = false;
                DirectionTimer = 0.0f;
                State          = STATE.WAIT;
            }
        }
    }