Exemplo n.º 1
0
        public Task <Player> Create(NewPlayer player)
        {
            Player _player = new Player();

            _player.Id           = Guid.NewGuid();
            _player.Name         = player.Name;
            _player.Score        = 0;
            _player.IsBanned     = false;
            _player.CreationTime = DateTime.Now;

            return(_IRepository.Create(_player));
        }
Exemplo n.º 2
0
 public Task <Player> Create([FromBody] NewPlayer player)
 {
     return(_PlayerProcessor.Create(player));
 }