示例#1
0
        private static void SetShip(Ship.GenericShip ship, int count)
        {
            float distance = CalculateDistance(ship.Owner.Ships.Count);
            float side     = (ship.Owner.PlayerNo == Players.PlayerNo.Player1) ? -1 : 1;

            ship.SetPosition(BoardIntoWorld(new Vector3(-SIZE_X / 2 + count * distance, 0, side * SIZE_Y / 2 + +side * 2 * RANGE_1)));
            ship.SetPosition(BoardIntoWorld(new Vector3(-SIZE_X / 2 + count * distance, 0, side * SIZE_Y / 2 + -side * 2 * RANGE_1)));
        }