public void Execute() { foreach (var x in ItemListManager.GetFUTListItems()) { x.LastPriceCheck = 0; x.SaveChanges(); } FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Pricechecks resetted"); }
public void Execute() { foreach (var x in ItemListManager.GetFUTListItems()) { x.SellPercent = Percentage; x.SaveChanges(); } FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Buypercent set to " + Percentage); }
public async Task RunMuleApiClientAsync(FUTClient client, MuleApiPlayer muleApiPlayer) { client.AddLog($"Starting {muleApiPlayer.MuleApiType} MuleApi!"); //var running = client.LogicRunningReal; //var runningCounter = 0; //if (running) //{ // client.AddLog($"Stopping Logic for MuleApi {muleApiPlayer.MuleApiType} transaction!"); // BotManager.StopBot(client.FUTAccount.EMail); // while (client.LogicRunningReal) // { // await Task.Delay(1000); // if (runningCounter++ > 30) // { // client.AddLog($"Couldn't stop account!"); // client.StartLogic(); // return; // } // } //} var mule = new MuleApiClient(client, muleApiPlayer); var result = await mule.MuleLogicAsync(); if (result) { switch (muleApiPlayer.MuleApiType) { case MuleApiType.GameTradeEasy: FUTMuleApiStatistic.Instance.GTETotalCoinVolume += muleApiPlayer.MuleValue; FUTMuleApiStatistic.Instance.GTETotalDollarVolume += muleApiPlayer.Revenue; break; case MuleApiType.MuleFactory: FUTMuleApiStatistic.Instance.MFTotalCoinVolume += muleApiPlayer.MuleValue; FUTMuleApiStatistic.Instance.MFTotalDollarVolume += muleApiPlayer.Revenue; break; case MuleApiType.WholeSale: FUTMuleApiStatistic.Instance.WSTotalCoinVolume += muleApiPlayer.MuleValue; FUTMuleApiStatistic.Instance.WSTotalDollarVolume += muleApiPlayer.Revenue; break; } FUTMuleApiStatistic.Instance.SaveChanges(); client.CoinsMuledToday += muleApiPlayer.MuleValue; await muleApiPlayer.MuleApiClient.UpdatePlayerStatusAsync(muleApiPlayer.TransactionId, MuleApiStatus.Bought); FUTLogsDatabase.AddFUTNotification(client.FUTAccount.EMail, $"Muling API sold {muleApiPlayer.MuleValue} coins for {muleApiPlayer.Revenue}$ to {muleApiPlayer.MuleApiType}"); client.AddLog($"Muling API sold {muleApiPlayer.MuleValue} coins for {muleApiPlayer.Revenue}$ to {muleApiPlayer.MuleApiType}"); } else { await muleApiPlayer.MuleApiClient.UpdatePlayerStatusAsync(muleApiPlayer.TransactionId, MuleApiStatus.Cancel); client.AddLog($"Muling API failed! {muleApiPlayer.MuleValue} coins for {muleApiPlayer.Revenue}$ to {muleApiPlayer.MuleApiType}"); } client.Muling = false; client.MulingPausedUntil = DateTime.Now.AddMinutes(FUTSettings.Instance.MuleApiSellDelayPerAccount); //if (running) //{ // client.AddLog($"Restarting account!"); // client.StartLogic(); //} }
public void Execute() { FUTSettings.Instance.EnableSell = false; FUTSettings.Instance.SaveChanges(); FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Sell disabled"); }
public void Execute() { FUTSettings.Instance.EnableBuy = true; FUTSettings.Instance.SaveChanges(); FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Buy enabled"); }
public void Execute() { BotManager.StartAllBots(); FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Logic started"); }
public void Execute() { FUTSettings.Instance.LoginMethod = LoginMethod.Android; FUTSettings.Instance.SaveChanges(); FUTLogsDatabase.AddFUTNotification("ActionScheduler", "Loginmethod switched to Android"); }