BattleshipUtility.BattleshipGame.GetEnemyPositions C# (CSharp) Method

GetEnemyPositions() static private method

When a win/loss/tie command is received, it is followed with a list of enemy positions - read these
static private GetEnemyPositions ( ) : void
return void
        void GetEnemyPositions()
        {
            StringBuilder sb = new StringBuilder();
            string s = String.Empty;
            List<Ship> enemyPositions = new List<Ship>();

            while (s != null)
            {
                sb.AppendLine(s);
                s = Console.ReadLine();

                if (s != null)
                {
            #if DEBUG
                    _player.Log("<< " + s);
            #endif
                    enemyPositions.Add(Ship.Parse(s));
                    if (enemyPositions.Count == _shipCount)
                        break;
                }
            }
            Debug.WriteLine(sb.ToString());
            _player.Offense.RegisterEnemyPositions(enemyPositions);
        }