Beispiel #1
0
        //ジャンプ中移行チェック
        private void JumpingMove()
        {
            int direction = 0;

            if (childDirection.IsNowRight())
            {
                entity.transform.Angle = 360;
                childDirection.SetRight(true);
                direction = 1;
                speed     = startSpeed;
            }
            else if (childDirection.IsNowLeft())
            {
                entity.transform.Angle = 180;
                childDirection.SetLeft(true);
                direction = -1;
                speed     = startSpeed;
            }
            else
            {
                entity.transform.Angle = 360;
                childDirection.SetNone();
            }

            //横移動後チェック
            entity.transform.Position += new Vector2((int)speed * direction, 0);

            //MovePointCheck
            bezierPoint.CheckJumpMove();
        }