Minor changes

This commit is contained in:
Lucas Nicodemus 2012-01-01 13:21:23 -07:00
parent 91e386bb67
commit ff84198e32
4 changed files with 8 additions and 6 deletions

View file

@ -14,6 +14,7 @@
<TargetFrameworkProfile>
</TargetFrameworkProfile>
<FileAlignment>512</FileAlignment>
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
@ -26,7 +27,6 @@
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
@ -110,6 +110,7 @@
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<None Include="TShockDBEditor.licenseheader" />
</ItemGroup>
<ItemGroup>
<WCFMetadata Include="Service References\" />

View file

@ -29,16 +29,16 @@ namespace TShockAPI
public DateTime lastcheck = DateTime.MinValue;
private readonly int checkinFrequency = 5;
public void checkin()
public void CheckIn()
{
if ((DateTime.Now - lastcheck).TotalMinutes >= checkinFrequency)
{
ThreadPool.QueueUserWorkItem(callHome);
ThreadPool.QueueUserWorkItem(CallHome);
lastcheck = DateTime.Now;
}
}
private void callHome(object state)
private void CallHome(object state)
{
string fp;
string lolpath = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "/.tshock/";

View file

@ -416,7 +416,7 @@ namespace TShockAPI
if (Config.RestApiEnabled)
RestApi.Start();
StatTracker.checkin();
StatTracker.CheckIn();
FixChestStacks();
}
@ -442,7 +442,7 @@ namespace TShockAPI
private void OnUpdate()
{
UpdateManager.UpdateProcedureCheck();
StatTracker.checkin();
StatTracker.CheckIn();
if (Backups.IsBackupTime)
Backups.Backup();

View file

@ -101,6 +101,7 @@
<None Include="RegionManagerTest.orderedtest">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="UnitTests.licenseheader" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.0">