Exemple #1
0
        public IActionResult CreateRandomly(string game, [FromBody] RandomCharacterCreationObject charac)
        {
            if (charac == null)
            {
                charac = new RandomCharacterCreationObject();
            }

            _logger.Log("In create randomly with parameter " + charac.Name);

            //charac.GameName = game;

            var myCharac = _service.CreateRandomly(game, charac);
            var response = new CharacterViewModel(myCharac);

            return(Ok(response));
        }