Threaded the server stat tracking thingy.

Rockin' Server!
This commit is contained in:
Lucas Nicodemus 2011-12-05 22:56:03 -07:00
parent fb7a63be78
commit ec78a4c748
2 changed files with 19 additions and 6 deletions

View file

@ -251,7 +251,9 @@ namespace TShockAPI
try
{
string response = client.DownloadString("http://tshock.co/tickto.php?do=log&fp=" + fp + "&ver=" + VersionNum + "&port=" + Netplay.serverPort);
Console.WriteLine("Registered with stat tracker: " + response);
Console.ForegroundColor = ConsoleColor.Cyan;
Console.WriteLine("\nRegistered with stat tracker: " + response + "\n");
Console.ForegroundColor = ConsoleColor.Gray;
}
catch (Exception e)
{
@ -432,9 +434,10 @@ namespace TShockAPI
Regions.ReloadAllRegions();
if (Config.RestApiEnabled)
RestApi.Start();
Console.ForegroundColor = ConsoleColor.Cyan;
callHome();
Console.ForegroundColor = ConsoleColor.Gray;
Thread t = new Thread(callHome);
t.Start();
}