Пример #1
0
        private void FinishSelectingCharacters(GamePlayer p)
        {
            var charactersPerPlayer = GetCharactersPerPlayer();

            if (SpriteSelect.Instance.SelectedObjects.Count != charactersPerPlayer)
            {
                return;
            }

            IEnumerable <string> names = SpriteSelect.Instance.SelectedObjects.Select(o => o.Name);

            p.AddCharacters(names);
            p.HasSelectedCharacters = true;
            SpriteSelect.Instance.Close();
        }