/// <summary> /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void OnGameHostChanged(object sender, GameHostChangedEventArgs e) { if (e.UserId == OnlineManager.Self.OnlineUser.Id) { ReadyUp.ChangeText("START MATCH"); if (!RightAligned.Contains(SelectMap)) { RightAligned.Add(SelectMap); } if (!RightAligned.Contains(SelectModifiers)) { RightAligned.Add(SelectModifiers); } } else { if (OnlineManager.CurrentGame.PlayersReady.Contains(OnlineManager.Self.OnlineUser.Id)) { ReadyUp.ChangeText("UNREADY"); } else { ReadyUp.ChangeText("READY"); } RightAligned.Remove(SelectMap); SelectMap.Parent = null; } AlignRightItems(RightAligned); }
/// <summary> /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void OnGameHostChanged(object sender, GameHostChangedEventArgs e) => HostCrown.Visible = e.UserId == Item.Id;
/// <summary> /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// <exception cref="NotImplementedException"></exception> private void OnGameHostChanged(object sender, GameHostChangedEventArgs e) => Close(false);