mirror of
https://github.com/tribufu/ServerManagers
synced 2026-05-06 15:17:34 +00:00
Fixed a bug when starting the server manager and it tries to download steamcmd, but fails as steamcmd is unavailable for download.
This commit is contained in:
parent
8ed965307a
commit
dbeaa7699d
11 changed files with 94 additions and 27 deletions
|
|
@ -127,6 +127,7 @@
|
|||
<sys:String x:Key="AutoUpdater_Status_DownloadNewServerComplete">Server download complete</sys:String>
|
||||
<sys:String x:Key="AutoUpdater_Status_Complete">Complete</sys:String>
|
||||
<sys:String x:Key="AutoUpdater_Status_Cancelled">Cancelled</sys:String>
|
||||
<sys:String x:Key="AutoUpdater_Status_Failed">Failed</sys:String>
|
||||
<sys:String x:Key="AutoUpdater_CancelButtonLabel">Cancel</sys:String>
|
||||
<!--#endregion-->
|
||||
|
||||
|
|
|
|||
|
|
@ -9,8 +9,8 @@
|
|||
|
||||
<entry>
|
||||
<id>urn:uuid:18276A38-2C71-4BB8-9A83-96D5EBFE9C87</id>
|
||||
<title>1.1.412 (1.1.412.3)</title>
|
||||
<summary>1.1.412.3</summary>
|
||||
<title>1.1.412 (1.1.412.4)</title>
|
||||
<summary>1.1.412.4</summary>
|
||||
<link href="" />
|
||||
<updated>2021-12-15T00:00:00Z</updated>
|
||||
<content type="xhtml">
|
||||
|
|
@ -22,6 +22,7 @@
|
|||
<li>Fixed a bug with the Server Shutdown when the CheckForOnlinePlayers option not selected.</li>
|
||||
<li>Fixed a bug when the backup path was a root directory that caused a 'Invalid URI: A Dos path must be rooted' crash.</li>
|
||||
<li>Added additional validation when setting directories in the global setting, to ensure they are rooted correctly.</li>
|
||||
<li>Fixed a bug when starting the server manager and it tries to download steamcmd, but fails as steamcmd is unavailable for download.</li>
|
||||
</ul>
|
||||
<u style="font-size: .9em;">CHANGE</u>
|
||||
<br/>
|
||||
|
|
|
|||
|
|
@ -7,6 +7,29 @@
|
|||
<link href="http://arkservermanager.freeforums.net/" />
|
||||
<updated>2021-12-15T00:00:00Z</updated>
|
||||
|
||||
<entry>
|
||||
<id>urn:uuid:202642C9-3B71-4B90-8A43-EFA1C5272C81</id>
|
||||
<title>1.1.412 (1.1.412.4)</title>
|
||||
<summary>1.1.412.4</summary>
|
||||
<link href="" />
|
||||
<updated>2021-12-15T00:00:00Z</updated>
|
||||
<content type="xhtml">
|
||||
<div xmlns="http://www.w3.org/1999/xhtml" style="font-family: Arial, Verdana, Helvetica, Sans-Serif;font-size: .8em;">
|
||||
<p>
|
||||
<u style="font-size: .9em;">BUGFIX</u>
|
||||
<br/>
|
||||
<ul>
|
||||
<li>Fixed a bug when starting the server manager and it tries to download steamcmd, but fails as steamcmd is unavailable for download.</li>
|
||||
</ul>
|
||||
</p>
|
||||
</div>
|
||||
</content>
|
||||
<author>
|
||||
<name>bletch</name>
|
||||
<email>bletch1971@hotmail.com</email>
|
||||
</author>
|
||||
</entry>
|
||||
|
||||
<entry>
|
||||
<id>urn:uuid:B7DE873D-4FC3-4A7B-A531-3146B4D8639A</id>
|
||||
<title>1.1.412 (1.1.412.3)</title>
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@
|
|||
<ProgressBar x:Name="CompletionProgress" Height="10"/>
|
||||
<Label x:Name="StatusLabel" Content="{DynamicResource AutoUpdater_Status}" HorizontalContentAlignment="Center"/>
|
||||
<Button Content="{DynamicResource AutoUpdater_CancelButtonLabel}" Width="75" HorizontalAlignment="Center" IsCancel="True" Click="Button_Click"/>
|
||||
<TextBlock x:Name="ErrorLabel" Text="Error Text" Margin="0,2,0,0" TextWrapping="Wrap" HorizontalAlignment="Center" VerticalAlignment="Center" FontWeight="Bold" Foreground="{DynamicResource WarningMessage}"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Window>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
using ServerManagerTool.Common.Utils;
|
||||
using System;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using WPFSharp.Globalizer;
|
||||
|
||||
|
|
@ -12,15 +13,16 @@ namespace ServerManagerTool
|
|||
/// </summary>
|
||||
public partial class AutoUpdateWindow : Window
|
||||
{
|
||||
private GlobalizedApplication _globalizer = GlobalizedApplication.Instance;
|
||||
|
||||
private SteamCmdUpdater updater = new SteamCmdUpdater();
|
||||
private readonly GlobalizedApplication _globalizer = GlobalizedApplication.Instance;
|
||||
private readonly SteamCmdUpdater updater = new SteamCmdUpdater();
|
||||
private CancellationTokenSource cancelSource;
|
||||
|
||||
public AutoUpdateWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
WindowUtils.RemoveDefaultResourceDictionary(this, Config.Default.DefaultGlobalizationFile);
|
||||
|
||||
this.ErrorLabel.Visibility = Visibility.Collapsed;
|
||||
}
|
||||
|
||||
private void Window_Loaded(object sender, RoutedEventArgs e)
|
||||
|
|
@ -32,10 +34,13 @@ namespace ServerManagerTool
|
|||
this.StatusLabel.Content = message;
|
||||
this.CompletionProgress.Value = u.CompletionPercent;
|
||||
|
||||
if(u.FailureText != null)
|
||||
if (u.FailureText != null)
|
||||
{
|
||||
// TODO: Report error through UI
|
||||
throw new Exception(u.FailureText);
|
||||
this.ErrorLabel.Text = u.FailureText;
|
||||
this.ErrorLabel.Visibility = Visibility.Visible;
|
||||
await Task.Delay(10000);
|
||||
|
||||
Environment.Exit(1);
|
||||
}
|
||||
|
||||
if (u.CompletionPercent >= 100 || u.Cancelled)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue