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); }
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" ); }