Skip to content

Commit

Permalink
http_timeout argument (int ms) for PostSubmitter
Browse files Browse the repository at this point in the history
added AreaBuff and RemoveBuff to BuffManager
new mail type BlackMarketAuctionWon (library.swf)
  • Loading branch information
fedorovvl committed Oct 18, 2022
1 parent 39dd9dd commit 97b0b4d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion client/Main.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ public partial class Main : Window, INotifyPropertyChanged
public static bool auto = false;
public static CookieCollection _cookies;
public static string _region = string.Empty;
public static int http_timeout = 10000;
private int _regionUid;
public static Arguments cmd;
private string _langLogin;
Expand All @@ -38,7 +39,7 @@ public partial class Main : Window, INotifyPropertyChanged
private string _langRemember;
public string appversion
{
get { return "1.4.9.0"; }
get { return "1.5.0.0"; }
}
public string langLogin
{
Expand Down Expand Up @@ -107,6 +108,8 @@ private void Main_Loaded(object sender, RoutedEventArgs e)
skipCheck = true;
if (cmd["debug"] != null)
debug = true;
if (cmd["http_timeout"] != null && IsNumeric(cmd["http_timeout"]))
http_timeout = int.Parse(cmd["http_timeout"]);
if (cmd["lang"] != null)
{
if (Servers._langs.ContainsKey(cmd["lang"]))
Expand Down Expand Up @@ -156,7 +159,13 @@ private void AutoLogin()
Thread.Sleep(1);
Dispatcher.BeginInvoke(new ThreadStart(delegate { butt_Click_1(null, null); }));
}
public static bool IsNumeric(object Expression)
{
double retNum;

bool isNum = Double.TryParse(Convert.ToString(Expression), System.Globalization.NumberStyles.Any, System.Globalization.NumberFormatInfo.InvariantInfo, out retNum);
return isNum;
}
public void checkVersion()
{
AutoUpdater.InstalledVersion = new Version(appversion);
Expand Down
2 changes: 1 addition & 1 deletion client/PostSubmitter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ private string PostData(string url,
request.Headers.Add("Accept-Encoding: gzip, deflate");
}
request.ContentType = contentType;
request.Timeout = 10000;
request.Timeout = Main.http_timeout;
request.Referer = "http://game-cdn.thesettlersonline.net/prestaging/PS5724/SWMMO/debug/SWMMO.swf";
request.CookieContainer = new CookieContainer();
if ((null != Cookies) && (0 != Cookies.Count))
Expand Down
Binary file modified client/files/content.zip
Binary file not shown.
Binary file modified client/files/content_86.zip
Binary file not shown.

0 comments on commit 97b0b4d

Please sign in to comment.