Compare commits
No commits in common. "a13d30f0b2a4fbd16ef1608805c24714a1b99590" and "aed74984c6cd33a64660524b6fcfbe2ee782b775" have entirely different histories.
a13d30f0b2
...
aed74984c6
3 changed files with 0 additions and 45 deletions
|
|
@ -66,7 +66,6 @@ namespace MosswartMassacre
|
||||||
private static Timer vitalsTimer;
|
private static Timer vitalsTimer;
|
||||||
private static System.Windows.Forms.Timer commandTimer;
|
private static System.Windows.Forms.Timer commandTimer;
|
||||||
private static Timer characterStatsTimer;
|
private static Timer characterStatsTimer;
|
||||||
private static Timer _updateCheckTimer;
|
|
||||||
private static readonly Queue<string> pendingCommands = new Queue<string>();
|
private static readonly Queue<string> pendingCommands = new Queue<string>();
|
||||||
private static RareTracker _staticRareTracker;
|
private static RareTracker _staticRareTracker;
|
||||||
public static bool RareMetaEnabled
|
public static bool RareMetaEnabled
|
||||||
|
|
@ -199,12 +198,6 @@ namespace MosswartMassacre
|
||||||
commandTimer.Dispose();
|
commandTimer.Dispose();
|
||||||
commandTimer = null;
|
commandTimer = null;
|
||||||
}
|
}
|
||||||
if (_updateCheckTimer != null)
|
|
||||||
{
|
|
||||||
_updateCheckTimer.Stop();
|
|
||||||
_updateCheckTimer.Dispose();
|
|
||||||
_updateCheckTimer = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Initialize kill tracker (owns the 1-sec stats timer)
|
// Initialize kill tracker (owns the 1-sec stats timer)
|
||||||
_killTracker = new KillTracker(
|
_killTracker = new KillTracker(
|
||||||
|
|
@ -303,17 +296,6 @@ namespace MosswartMassacre
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Auto-update: check for updates 30s after startup
|
|
||||||
_updateCheckTimer = new Timer(30000);
|
|
||||||
_updateCheckTimer.AutoReset = false;
|
|
||||||
_updateCheckTimer.Elapsed += (s, ev) =>
|
|
||||||
{
|
|
||||||
Task.Run(() => UpdateManager.CheckAndInstallAsync());
|
|
||||||
_updateCheckTimer?.Dispose();
|
|
||||||
_updateCheckTimer = null;
|
|
||||||
};
|
|
||||||
_updateCheckTimer.Start();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
|
@ -379,13 +361,6 @@ namespace MosswartMassacre
|
||||||
characterStatsTimer = null;
|
characterStatsTimer = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (_updateCheckTimer != null)
|
|
||||||
{
|
|
||||||
_updateCheckTimer.Stop();
|
|
||||||
_updateCheckTimer.Dispose();
|
|
||||||
_updateCheckTimer = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Dispose quest manager
|
// Dispose quest manager
|
||||||
if (questManager != null)
|
if (questManager != null)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -206,26 +206,6 @@ namespace MosswartMassacre
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Check for update and auto-install if available. Used by startup auto-update.
|
|
||||||
/// </summary>
|
|
||||||
public static async Task CheckAndInstallAsync()
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
bool checkOk = await CheckForUpdateAsync();
|
|
||||||
if (checkOk && updateAvailable)
|
|
||||||
{
|
|
||||||
PluginCore.WriteToChat("[Update] Auto-installing update...");
|
|
||||||
await DownloadAndInstallUpdateAsync();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
PluginCore.WriteToChat($"[Update] Auto-update failed: {ex.Message}");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static string GetLocalDllPath()
|
private static string GetLocalDllPath()
|
||||||
{
|
{
|
||||||
// Get the path to the current DLL
|
// Get the path to the current DLL
|
||||||
|
|
|
||||||
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue