Beispiel #1
0
 public IActionResult StartBattle([FromBody] StartBattleModel model)
 {
     return(RunWithException(() => this.battleService.StartBattle(model.AttackerId, model.DefenderId), Ok));
 }
Beispiel #2
0
 public async Task <IActionResult> StartBattle([FromBody] StartBattleModel model)
 {
     return(await RunWithException(() => mediator.Send(new StartBattleCommand(model.AttackerId, model.DefenderId)), Ok));
 }