(ad567dea) v0.9.7.1
This commit is contained in:
@@ -443,7 +443,7 @@ namespace Barotrauma
|
||||
{
|
||||
OnClicked = (btn, userdata) =>
|
||||
{
|
||||
if (!(FileTransferFrame.UserData is FileReceiver.FileTransferIn transfer)) { return false; }
|
||||
if (!(userdata is FileReceiver.FileTransferIn transfer)) { return false; }
|
||||
GameMain.Client?.CancelFileTransfer(transfer);
|
||||
GameMain.Client.FileReceiver.StopTransfer(transfer);
|
||||
return true;
|
||||
@@ -658,7 +658,7 @@ namespace Barotrauma
|
||||
OnClicked = (btn, obj) =>
|
||||
{
|
||||
GameMain.Client.RequestStartRound();
|
||||
CoroutineManager.StartCoroutine(WaitForStartRound(StartButton, allowCancel: false), "WaitForStartRound");
|
||||
CoroutineManager.StartCoroutine(WaitForStartRound(StartButton, allowCancel: true), "WaitForStartRound");
|
||||
return true;
|
||||
}
|
||||
};
|
||||
@@ -1147,22 +1147,6 @@ namespace Barotrauma
|
||||
clientDisabledElements.AddRange(botSpawnModeButtons);
|
||||
}
|
||||
|
||||
public void StopWaitingForStartRound()
|
||||
{
|
||||
CoroutineManager.StopCoroutines("WaitForStartRound");
|
||||
|
||||
GUIMessageBox.CloseAll();
|
||||
if (StartButton != null)
|
||||
{
|
||||
StartButton.Enabled = true;
|
||||
}
|
||||
if (campaignUI?.StartButton != null)
|
||||
{
|
||||
campaignUI.StartButton.Enabled = true;
|
||||
}
|
||||
GUI.ClearCursorWait();
|
||||
}
|
||||
|
||||
public IEnumerable<object> WaitForStartRound(GUIButton startButton, bool allowCancel)
|
||||
{
|
||||
GUI.SetCursorWaiting();
|
||||
@@ -1189,8 +1173,7 @@ namespace Barotrauma
|
||||
}
|
||||
|
||||
DateTime timeOut = DateTime.Now + new TimeSpan(0, 0, 10);
|
||||
while (Selected == GameMain.NetLobbyScreen &&
|
||||
DateTime.Now < timeOut)
|
||||
while (Selected == GameMain.NetLobbyScreen && DateTime.Now < timeOut)
|
||||
{
|
||||
msgBox.Header.Text = headerText + new string('.', ((int)Timing.TotalTime % 3 + 1));
|
||||
yield return CoroutineStatus.Running;
|
||||
@@ -1339,8 +1322,6 @@ namespace Barotrauma
|
||||
if (GameMain.Client == null) return;
|
||||
spectateButton.Visible = true;
|
||||
spectateButton.Enabled = true;
|
||||
|
||||
StartButton.Visible = false;
|
||||
}
|
||||
|
||||
public void SetCampaignCharacterInfo(CharacterInfo newCampaignCharacterInfo)
|
||||
@@ -1780,7 +1761,7 @@ namespace Barotrauma
|
||||
}
|
||||
GameMain.Client.RequestSelectMode(component.Parent.GetChildIndex(component));
|
||||
HighlightMode(SelectedModeIndex);
|
||||
return !presetName.Equals("multiplayercampaign", StringComparison.OrdinalIgnoreCase);
|
||||
return (presetName.ToLowerInvariant() != "multiplayercampaign");
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@@ -2260,7 +2241,7 @@ namespace Barotrauma
|
||||
targetMicStyle = "GUIMicrophoneDisabled";
|
||||
}
|
||||
|
||||
if (!targetMicStyle.Equals(currMicStyle, StringComparison.OrdinalIgnoreCase))
|
||||
if (targetMicStyle.ToLowerInvariant() != currMicStyle.ToLowerInvariant())
|
||||
{
|
||||
GUI.Style.Apply(micIcon, targetMicStyle);
|
||||
}
|
||||
@@ -2616,7 +2597,7 @@ namespace Barotrauma
|
||||
GUILayoutGroup row = null;
|
||||
int itemsInRow = 0;
|
||||
|
||||
XElement headElement = info.Ragdoll.MainElement.Elements().FirstOrDefault(e => e.GetAttributeString("type", "").Equals("head", StringComparison.OrdinalIgnoreCase));
|
||||
XElement headElement = info.Ragdoll.MainElement.Elements().FirstOrDefault(e => e.GetAttributeString("type", "").ToLowerInvariant() == "head");
|
||||
XElement headSpriteElement = headElement.Element("sprite");
|
||||
string spritePathWithTags = headSpriteElement.Attribute("texture").Value;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user