public void GameHostChangedEvent(IGameHostChangedEvent e)
 {
     if (e.NewHost == null)
     {
         return; // No new host, game ending
     }
     _proximityHub.Clients.Group(e.Game.Code).HostChange(e.NewHost.Client.Name);
 }
Ejemplo n.º 2
0
 public void OnGameHostChanged(IGameHostChangedEvent e)
 {
     _logger.LogInformation(
         "Game {code} > changed host from {previous} to {new}",
         e.Game.Code,
         e.PreviousHost.Character?.PlayerInfo.PlayerName,
         e.NewHost != null ? e.NewHost.Character?.PlayerInfo.PlayerName : "none"
         );
 }