Update to latest TSAPI. Changed update manager to use same code as stat tracker, which hopefully doesnt break on mono. Also changed it to not check every update to see if time has passed. Made packetbufferer async for windows and if specified for mono. Fixed maxspawns error message to explain range. Ticked version.

This commit is contained in:
Zack Piispanen 2014-09-09 03:49:57 -04:00
parent 1421c23df7
commit 444af6cf57
8 changed files with 83 additions and 52 deletions

View file

@ -77,6 +77,7 @@ namespace TShockAPI
public static RestManager RestManager;
public static Utils Utils = Utils.Instance;
public static StatTracker StatTracker = new StatTracker();
public static UpdateManager UpdateManager;
/// <summary>
/// Used for implementing REST Tokens prior to the REST system starting up.
/// </summary>
@ -613,6 +614,7 @@ namespace TShockAPI
FixChestStacks();
StatTracker.Initialize();
UpdateManager = new UpdateManager();
}
private void ComputeMaxStyles()
@ -656,7 +658,6 @@ namespace TShockAPI
private void OnUpdate(EventArgs args)
{
UpdateManager.UpdateProcedureCheck();
if (Backups.IsBackupTime)
Backups.Backup();
//call these every second, not every update