From 8f26b17c9a16bdf4e4017d4ec1478843ff990a45 Mon Sep 17 00:00:00 2001 From: JustArchi Date: Sun, 19 Feb 2017 12:32:34 +0100 Subject: [PATCH] Fix SendTradePeriod not triggering This got broken around V2.1.5.9, in https://github.com/JustArchi/ArchiSteamFarm/commit/f108829129377aa360ea068823306ec2ffc6b0e6 so almost 5 MONTHS ago, it's a miracle that nobody reported it yet, especially because old AcceptConfirmationsPeriod was also affected --- ArchiSteamFarm/Bot.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ArchiSteamFarm/Bot.cs b/ArchiSteamFarm/Bot.cs index 2c775bd27..3bb049b69 100755 --- a/ArchiSteamFarm/Bot.cs +++ b/ArchiSteamFarm/Bot.cs @@ -219,6 +219,15 @@ namespace ArchiSteamFarm { Statistics = new Statistics(this); } + if ((BotConfig.SendTradePeriod > 0) && (BotConfig.SteamMasterID != 0)) { + SendItemsTimer = new Timer( + async e => await ResponseLoot(BotConfig.SteamMasterID).ConfigureAwait(false), + null, + TimeSpan.FromHours(BotConfig.SendTradePeriod) + TimeSpan.FromMinutes(Bots.Count), // Delay + TimeSpan.FromHours(BotConfig.SendTradePeriod) // Period + ); + } + HeartBeatTimer = new Timer( async e => await HeartBeat().ConfigureAwait(false), null,