mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2025-12-19 15:58:39 +00:00
Compare commits
20 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d1bbaba40c | ||
|
|
9fbe53358d | ||
|
|
78a86997b6 | ||
|
|
699ef5b06d | ||
|
|
648c2f2509 | ||
|
|
efb91f0886 | ||
|
|
ba8d70aebb | ||
|
|
8edbe3321a | ||
|
|
7de9fdc69a | ||
|
|
e13fd2d861 | ||
|
|
5d21cd3452 | ||
|
|
b316224af3 | ||
|
|
c210480231 | ||
|
|
a44d097d4e | ||
|
|
df1e83130d | ||
|
|
2f1b6311ac | ||
|
|
2c1127e57b | ||
|
|
9722059bb0 | ||
|
|
cb077a2c4a | ||
|
|
fb21b225bc |
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -127,6 +127,7 @@ namespace ArchiSteamFarm {
|
|||||||
return htmlDocument?.DocumentNode.SelectSingleNode("//div[@class='add_free_content_success_area']") != null;
|
return htmlDocument?.DocumentNode.SelectSingleNode("//div[@class='add_free_content_success_area']") != null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
internal async Task<bool> ClearFromDiscoveryQueue(uint appID) {
|
internal async Task<bool> ClearFromDiscoveryQueue(uint appID) {
|
||||||
if (appID == 0) {
|
if (appID == 0) {
|
||||||
Bot.ArchiLogger.LogNullError(nameof(appID));
|
Bot.ArchiLogger.LogNullError(nameof(appID));
|
||||||
@@ -151,6 +152,7 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
return await WebBrowser.UrlPostRetry(request, data).ConfigureAwait(false);
|
return await WebBrowser.UrlPostRetry(request, data).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
internal void DeclineTradeOffer(ulong tradeID) {
|
internal void DeclineTradeOffer(ulong tradeID) {
|
||||||
if ((tradeID == 0) || string.IsNullOrEmpty(Bot.BotConfig.SteamApiKey)) {
|
if ((tradeID == 0) || string.IsNullOrEmpty(Bot.BotConfig.SteamApiKey)) {
|
||||||
@@ -180,6 +182,7 @@ namespace ArchiSteamFarm {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
internal async Task<HashSet<uint>> GenerateNewDiscoveryQueue() {
|
internal async Task<HashSet<uint>> GenerateNewDiscoveryQueue() {
|
||||||
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
||||||
return null;
|
return null;
|
||||||
@@ -200,6 +203,7 @@ namespace ArchiSteamFarm {
|
|||||||
Steam.NewDiscoveryQueueResponse output = await WebBrowser.UrlPostToJsonResultRetry<Steam.NewDiscoveryQueueResponse>(request, data).ConfigureAwait(false);
|
Steam.NewDiscoveryQueueResponse output = await WebBrowser.UrlPostToJsonResultRetry<Steam.NewDiscoveryQueueResponse>(request, data).ConfigureAwait(false);
|
||||||
return output?.Queue;
|
return output?.Queue;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
internal HashSet<Steam.TradeOffer> GetActiveTradeOffers() {
|
internal HashSet<Steam.TradeOffer> GetActiveTradeOffers() {
|
||||||
if (string.IsNullOrEmpty(Bot.BotConfig.SteamApiKey)) {
|
if (string.IsNullOrEmpty(Bot.BotConfig.SteamApiKey)) {
|
||||||
@@ -360,6 +364,7 @@ namespace ArchiSteamFarm {
|
|||||||
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
internal async Task<HtmlDocument> GetDiscoveryQueuePage() {
|
internal async Task<HtmlDocument> GetDiscoveryQueuePage() {
|
||||||
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
||||||
return null;
|
return null;
|
||||||
@@ -368,6 +373,7 @@ namespace ArchiSteamFarm {
|
|||||||
const string request = SteamStoreURL + "/explore?l=english";
|
const string request = SteamStoreURL + "/explore?l=english";
|
||||||
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
internal async Task<HashSet<ulong>> GetFamilySharingSteamIDs() {
|
internal async Task<HashSet<ulong>> GetFamilySharingSteamIDs() {
|
||||||
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
||||||
@@ -649,6 +655,7 @@ namespace ArchiSteamFarm {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
internal async Task<HtmlDocument> GetSteamAwardsPage() {
|
internal async Task<HtmlDocument> GetSteamAwardsPage() {
|
||||||
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
if (!await RefreshSessionIfNeeded().ConfigureAwait(false)) {
|
||||||
return null;
|
return null;
|
||||||
@@ -657,6 +664,7 @@ namespace ArchiSteamFarm {
|
|||||||
const string request = SteamStoreURL + "/SteamAwards?l=english";
|
const string request = SteamStoreURL + "/SteamAwards?l=english";
|
||||||
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
return await WebBrowser.UrlGetToHtmlDocumentRetry(request).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
internal async Task<byte?> GetTradeHoldDuration(ulong tradeID) {
|
internal async Task<byte?> GetTradeHoldDuration(ulong tradeID) {
|
||||||
if (tradeID == 0) {
|
if (tradeID == 0) {
|
||||||
@@ -952,6 +960,7 @@ namespace ArchiSteamFarm {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
internal async Task<bool> SteamAwardsVote(byte voteID, uint appID) {
|
internal async Task<bool> SteamAwardsVote(byte voteID, uint appID) {
|
||||||
if ((voteID == 0) || (appID == 0)) {
|
if ((voteID == 0) || (appID == 0)) {
|
||||||
Bot.ArchiLogger.LogNullError(nameof(voteID) + " || " + nameof(appID));
|
Bot.ArchiLogger.LogNullError(nameof(voteID) + " || " + nameof(appID));
|
||||||
@@ -977,6 +986,7 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
return await WebBrowser.UrlPostRetry(request, data).ConfigureAwait(false);
|
return await WebBrowser.UrlPostRetry(request, data).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
private static uint GetAppIDFromMarketHashName(string hashName) {
|
private static uint GetAppIDFromMarketHashName(string hashName) {
|
||||||
if (string.IsNullOrEmpty(hashName)) {
|
if (string.IsNullOrEmpty(hashName)) {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -43,7 +43,7 @@ namespace ArchiSteamFarm {
|
|||||||
internal sealed class Bot : IDisposable {
|
internal sealed class Bot : IDisposable {
|
||||||
private const ushort CallbackSleep = 500; // In miliseconds
|
private const ushort CallbackSleep = 500; // In miliseconds
|
||||||
private const byte FamilySharingInactivityMinutes = 5;
|
private const byte FamilySharingInactivityMinutes = 5;
|
||||||
private const uint LoginID = 0; // This must be the same for all ASF bots and all ASF processes
|
private const uint LoginID = GlobalConfig.DefaultWCFPort; // This must be the same for all ASF bots and all ASF processes
|
||||||
private const ushort MaxSteamMessageLength = 2048;
|
private const ushort MaxSteamMessageLength = 2048;
|
||||||
|
|
||||||
internal static readonly ConcurrentDictionary<string, Bot> Bots = new ConcurrentDictionary<string, Bot>();
|
internal static readonly ConcurrentDictionary<string, Bot> Bots = new ConcurrentDictionary<string, Bot>();
|
||||||
@@ -82,7 +82,7 @@ namespace ArchiSteamFarm {
|
|||||||
private readonly SteamClient SteamClient;
|
private readonly SteamClient SteamClient;
|
||||||
private readonly ConcurrentHashSet<ulong> SteamFamilySharingIDs = new ConcurrentHashSet<ulong>();
|
private readonly ConcurrentHashSet<ulong> SteamFamilySharingIDs = new ConcurrentHashSet<ulong>();
|
||||||
private readonly SteamFriends SteamFriends;
|
private readonly SteamFriends SteamFriends;
|
||||||
private readonly SteamSaleEvent SteamSaleEvent;
|
//private readonly SteamSaleEvent SteamSaleEvent;
|
||||||
private readonly SteamUser SteamUser;
|
private readonly SteamUser SteamUser;
|
||||||
private readonly Trading Trading;
|
private readonly Trading Trading;
|
||||||
|
|
||||||
@@ -208,7 +208,7 @@ namespace ArchiSteamFarm {
|
|||||||
CardsFarmer = new CardsFarmer(this);
|
CardsFarmer = new CardsFarmer(this);
|
||||||
CardsFarmer.SetInitialState(BotConfig.Paused);
|
CardsFarmer.SetInitialState(BotConfig.Paused);
|
||||||
|
|
||||||
SteamSaleEvent = new SteamSaleEvent(this);
|
//SteamSaleEvent = new SteamSaleEvent(this);
|
||||||
Trading = new Trading(this);
|
Trading = new Trading(this);
|
||||||
|
|
||||||
if (Program.GlobalConfig.Statistics) {
|
if (Program.GlobalConfig.Statistics) {
|
||||||
@@ -235,7 +235,7 @@ namespace ArchiSteamFarm {
|
|||||||
InitializationSemaphore.Dispose();
|
InitializationSemaphore.Dispose();
|
||||||
SteamFamilySharingIDs.Dispose();
|
SteamFamilySharingIDs.Dispose();
|
||||||
OwnedPackageIDs.Dispose();
|
OwnedPackageIDs.Dispose();
|
||||||
SteamSaleEvent.Dispose();
|
//SteamSaleEvent.Dispose();
|
||||||
Trading.Dispose();
|
Trading.Dispose();
|
||||||
|
|
||||||
// Those are objects that might be null and the check should be in-place
|
// Those are objects that might be null and the check should be in-place
|
||||||
@@ -314,8 +314,13 @@ namespace ArchiSteamFarm {
|
|||||||
// Normally we wouldn't need to do this, but there is a case where our list might be invalid or outdated
|
// Normally we wouldn't need to do this, but there is a case where our list might be invalid or outdated
|
||||||
// Ensure that we always ask once for list of up-to-date servers, even if we have list saved
|
// Ensure that we always ask once for list of up-to-date servers, even if we have list saved
|
||||||
Program.ArchiLogger.LogGenericInfo("Initializing SteamDirectory...");
|
Program.ArchiLogger.LogGenericInfo("Initializing SteamDirectory...");
|
||||||
await SteamDirectory.Initialize(cellID).ConfigureAwait(false);
|
|
||||||
Program.ArchiLogger.LogGenericInfo("Done!");
|
try {
|
||||||
|
await SteamDirectory.Initialize(cellID).ConfigureAwait(false);
|
||||||
|
Program.ArchiLogger.LogGenericInfo("Done!");
|
||||||
|
} catch {
|
||||||
|
Program.ArchiLogger.LogGenericWarning("Could not initialize SteamDirectory, connecting with Steam Network might take much longer than usual!");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
internal async Task LootIfNeeded() {
|
internal async Task LootIfNeeded() {
|
||||||
@@ -1737,6 +1742,10 @@ namespace ArchiSteamFarm {
|
|||||||
return "You can't loot yourself!";
|
return "You can't loot yourself!";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (BotConfig.LootableTypes.Count == 0) {
|
||||||
|
return "You don't have any lootable types set!";
|
||||||
|
}
|
||||||
|
|
||||||
await Trading.LimitInventoryRequestsAsync().ConfigureAwait(false);
|
await Trading.LimitInventoryRequestsAsync().ConfigureAwait(false);
|
||||||
|
|
||||||
HashSet<Steam.Item> inventory = await ArchiWebHandler.GetMySteamInventory(true, BotConfig.LootableTypes).ConfigureAwait(false);
|
HashSet<Steam.Item> inventory = await ArchiWebHandler.GetMySteamInventory(true, BotConfig.LootableTypes).ConfigureAwait(false);
|
||||||
@@ -2363,12 +2372,12 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
if (CardsFarmer.CurrentGamesFarming.Count == 1) {
|
if (CardsFarmer.CurrentGamesFarming.Count == 1) {
|
||||||
CardsFarmer.Game game = CardsFarmer.CurrentGamesFarming.First();
|
CardsFarmer.Game game = CardsFarmer.CurrentGamesFarming.First();
|
||||||
response.Append("game " + game.AppID + " (" + game.GameName + ", " + game.CardsRemaining + " card drops remaining)");
|
response.Append("game: " + game.AppID + " (" + game.GameName + ", " + game.CardsRemaining + " card drops remaining)");
|
||||||
} else {
|
} else {
|
||||||
response.Append("appIDs " + string.Join(", ", CardsFarmer.CurrentGamesFarming.Select(game => game.AppID)));
|
response.Append("appIDs: " + string.Join(", ", CardsFarmer.CurrentGamesFarming.Select(game => game.AppID)));
|
||||||
}
|
}
|
||||||
|
|
||||||
response.Append(" and has a total of " + CardsFarmer.GamesToFarm.Count + " games (" + CardsFarmer.GamesToFarm.Sum(game => game.CardsRemaining) + " cards, about " + CardsFarmer.TimeRemaining.ToHumanReadable() + ") left to farm.");
|
response.Append(" and has a total of " + CardsFarmer.GamesToFarm.Count + " games (" + CardsFarmer.GamesToFarm.Sum(game => game.CardsRemaining) + " cards) left to farm (~" + CardsFarmer.TimeRemaining.ToHumanReadable() + " remaining).");
|
||||||
return response.ToString();
|
return response.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -72,7 +72,7 @@ namespace ArchiSteamFarm {
|
|||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
internal readonly bool IsBotAccount = false;
|
internal readonly bool IsBotAccount = false;
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)]
|
||||||
internal readonly HashSet<Steam.Item.EType> LootableTypes = new HashSet<Steam.Item.EType> { Steam.Item.EType.BoosterPack, Steam.Item.EType.FoilTradingCard, Steam.Item.EType.TradingCard };
|
internal readonly HashSet<Steam.Item.EType> LootableTypes = new HashSet<Steam.Item.EType> { Steam.Item.EType.BoosterPack, Steam.Item.EType.FoilTradingCard, Steam.Item.EType.TradingCard };
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -46,7 +46,7 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
[JsonProperty]
|
[JsonProperty]
|
||||||
internal TimeSpan TimeRemaining => new TimeSpan(
|
internal TimeSpan TimeRemaining => new TimeSpan(
|
||||||
Bot.BotConfig.CardDropsRestricted ? (int) Math.Ceiling(GamesToFarm.Count / (float) ArchiHandler.MaxGamesPlayedConcurrently * HoursToBump) : 0,
|
Bot.BotConfig.CardDropsRestricted ? (int) Math.Ceiling(GamesToFarm.Count / (float) ArchiHandler.MaxGamesPlayedConcurrently) * HoursToBump : 0,
|
||||||
30 * GamesToFarm.Sum(game => game.CardsRemaining),
|
30 * GamesToFarm.Sum(game => game.CardsRemaining),
|
||||||
0
|
0
|
||||||
);
|
);
|
||||||
@@ -172,7 +172,12 @@ namespace ArchiSteamFarm {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericInfo("We have a total of " + GamesToFarm.Count + " games (" + GamesToFarm.Sum(game => game.CardsRemaining) + " cards, about " + TimeRemaining.ToHumanReadable() + ") to farm on this account...");
|
if (GamesToFarm.Count == 0) {
|
||||||
|
Bot.ArchiLogger.LogNullError(nameof(GamesToFarm));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Bot.ArchiLogger.LogGenericInfo("We have a total of " + GamesToFarm.Count + " games (" + GamesToFarm.Sum(game => game.CardsRemaining) + " cards) left to farm (~" + TimeRemaining.ToHumanReadable() + " remaining)...");
|
||||||
|
|
||||||
// This is the last moment for final check if we can farm
|
// This is the last moment for final check if we can farm
|
||||||
if (!Bot.IsPlayingPossible) {
|
if (!Bot.IsPlayingPossible) {
|
||||||
@@ -608,8 +613,7 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
GamesToFarm.Remove(game);
|
GamesToFarm.Remove(game);
|
||||||
|
|
||||||
TimeSpan timeSpan = TimeSpan.FromHours(game.HoursPlayed);
|
Bot.ArchiLogger.LogGenericInfo("Done farming: " + game.AppID + " (" + game.GameName + ")" + (game.HoursPlayed > 0 ? " after " + TimeSpan.FromHours(game.HoursPlayed).ToHumanReadable() + " of playtime!" : ""));
|
||||||
Bot.ArchiLogger.LogGenericInfo("Done farming: " + game.AppID + " (" + game.GameName + ") after " + timeSpan.ToHumanReadable() + " of playtime!");
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -35,11 +35,11 @@ namespace ArchiSteamFarm {
|
|||||||
[SuppressMessage("ReSharper", "ConvertToConstant.Global")]
|
[SuppressMessage("ReSharper", "ConvertToConstant.Global")]
|
||||||
internal sealed class GlobalConfig {
|
internal sealed class GlobalConfig {
|
||||||
internal const byte DefaultHttpTimeout = 60;
|
internal const byte DefaultHttpTimeout = 60;
|
||||||
|
internal const ushort DefaultWCFPort = 1242;
|
||||||
|
|
||||||
private const byte DefaultFarmingDelay = 15;
|
private const byte DefaultFarmingDelay = 15;
|
||||||
private const byte DefaultMaxFarmingTime = 10;
|
private const byte DefaultMaxFarmingTime = 10;
|
||||||
private const ProtocolType DefaultSteamProtocol = ProtocolType.Tcp;
|
private const ProtocolType DefaultSteamProtocol = ProtocolType.Tcp;
|
||||||
private const ushort DefaultWCFPort = 1242;
|
|
||||||
|
|
||||||
// This is hardcoded blacklist which should not be possible to change
|
// This is hardcoded blacklist which should not be possible to change
|
||||||
internal static readonly HashSet<uint> GlobalBlacklist = new HashSet<uint> { 267420, 303700, 335590, 368020, 425280, 480730, 566020 };
|
internal static readonly HashSet<uint> GlobalBlacklist = new HashSet<uint> { 267420, 303700, 335590, 368020, 425280, 480730, 566020 };
|
||||||
@@ -50,7 +50,7 @@ namespace ArchiSteamFarm {
|
|||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
internal readonly bool AutoUpdates = true;
|
internal readonly bool AutoUpdates = true;
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)]
|
||||||
internal readonly HashSet<uint> Blacklist = new HashSet<uint>(GlobalBlacklist);
|
internal readonly HashSet<uint> Blacklist = new HashSet<uint>(GlobalBlacklist);
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -368,6 +368,7 @@ namespace ArchiSteamFarm.JSON {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
[SuppressMessage("ReSharper", "ClassCannotBeInstantiated")]
|
[SuppressMessage("ReSharper", "ClassCannotBeInstantiated")]
|
||||||
[SuppressMessage("ReSharper", "ClassNeverInstantiated.Global")]
|
[SuppressMessage("ReSharper", "ClassNeverInstantiated.Global")]
|
||||||
internal sealed class NewDiscoveryQueueResponse { // Deserialized from JSON
|
internal sealed class NewDiscoveryQueueResponse { // Deserialized from JSON
|
||||||
@@ -378,6 +379,7 @@ namespace ArchiSteamFarm.JSON {
|
|||||||
|
|
||||||
private NewDiscoveryQueueResponse() { }
|
private NewDiscoveryQueueResponse() { }
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
[SuppressMessage("ReSharper", "ClassCannotBeInstantiated")]
|
[SuppressMessage("ReSharper", "ClassCannotBeInstantiated")]
|
||||||
[SuppressMessage("ReSharper", "ClassNeverInstantiated.Global")]
|
[SuppressMessage("ReSharper", "ClassNeverInstantiated.Global")]
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -32,7 +32,7 @@ namespace ArchiSteamFarm {
|
|||||||
internal const string ASFDirectory = "ArchiSteamFarm";
|
internal const string ASFDirectory = "ArchiSteamFarm";
|
||||||
internal const ulong ASFGroupSteamID = 103582791440160998;
|
internal const ulong ASFGroupSteamID = 103582791440160998;
|
||||||
internal const string ConfigDirectory = "config";
|
internal const string ConfigDirectory = "config";
|
||||||
internal const string Copyright = "Copyright © ArchiSteamFarm 2015-2016";
|
internal const string Copyright = "Copyright © ArchiSteamFarm 2015-2017";
|
||||||
internal const string DebugDirectory = "debug";
|
internal const string DebugDirectory = "debug";
|
||||||
internal const string EventLog = ServiceName;
|
internal const string EventLog = ServiceName;
|
||||||
internal const string EventLogSource = EventLog + "Logger";
|
internal const string EventLogSource = EventLog + "Logger";
|
||||||
@@ -44,7 +44,7 @@ namespace ArchiSteamFarm {
|
|||||||
internal const string ServiceDescription = "ASF is an application that allows you to farm steam cards using multiple steam accounts simultaneously.";
|
internal const string ServiceDescription = "ASF is an application that allows you to farm steam cards using multiple steam accounts simultaneously.";
|
||||||
internal const string ServiceName = "ArchiSteamFarm";
|
internal const string ServiceName = "ArchiSteamFarm";
|
||||||
internal const string StatisticsServer = "asf.justarchi.net";
|
internal const string StatisticsServer = "asf.justarchi.net";
|
||||||
internal const string VersionNumber = "2.2.0.1";
|
internal const string VersionNumber = "2.2.0.5";
|
||||||
|
|
||||||
internal static readonly Version Version = Assembly.GetEntryAssembly().GetName().Version;
|
internal static readonly Version Version = Assembly.GetEntryAssembly().GetName().Version;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -1,4 +1,29 @@
|
|||||||
using System;
|
/*
|
||||||
|
_ _ _ ____ _ _____
|
||||||
|
/ \ _ __ ___ | |__ (_)/ ___| | |_ ___ __ _ _ __ ___ | ___|__ _ _ __ _ __ ___
|
||||||
|
/ _ \ | '__|/ __|| '_ \ | |\___ \ | __|/ _ \ / _` || '_ ` _ \ | |_ / _` || '__|| '_ ` _ \
|
||||||
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
@@ -52,30 +77,22 @@ namespace ArchiSteamFarm {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("Started!");
|
|
||||||
|
|
||||||
for (byte i = 0; (i < 3) && !(await IsDiscoveryQueueEmpty().ConfigureAwait(false)).GetValueOrDefault(); i++) {
|
for (byte i = 0; (i < 3) && !(await IsDiscoveryQueueEmpty().ConfigureAwait(false)).GetValueOrDefault(); i++) {
|
||||||
Bot.ArchiLogger.LogGenericDebug("Getting new queue...");
|
|
||||||
HashSet<uint> queue = await Bot.ArchiWebHandler.GenerateNewDiscoveryQueue().ConfigureAwait(false);
|
HashSet<uint> queue = await Bot.ArchiWebHandler.GenerateNewDiscoveryQueue().ConfigureAwait(false);
|
||||||
if (queue == null) {
|
if (queue == null) {
|
||||||
Bot.ArchiLogger.LogGenericWarning("Aborting due to error!");
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("We got new queue, clearing...");
|
// We could in theory do this in parallel, but who knows what would happen...
|
||||||
foreach (uint queuedAppID in queue) {
|
foreach (uint queuedAppID in queue) {
|
||||||
Bot.ArchiLogger.LogGenericDebug("Clearing " + queuedAppID + "...");
|
|
||||||
if (await Bot.ArchiWebHandler.ClearFromDiscoveryQueue(queuedAppID).ConfigureAwait(false)) {
|
if (await Bot.ArchiWebHandler.ClearFromDiscoveryQueue(queuedAppID).ConfigureAwait(false)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericWarning("Aborting due to error!");
|
|
||||||
i = byte.MaxValue;
|
i = byte.MaxValue;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("Done!");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task<bool?> IsDiscoveryQueueEmpty() {
|
private async Task<bool?> IsDiscoveryQueueEmpty() {
|
||||||
@@ -83,23 +100,20 @@ namespace ArchiSteamFarm {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("Checking if discovery queue is empty...");
|
|
||||||
HtmlDocument htmlDocument = await Bot.ArchiWebHandler.GetDiscoveryQueuePage().ConfigureAwait(false);
|
HtmlDocument htmlDocument = await Bot.ArchiWebHandler.GetDiscoveryQueuePage().ConfigureAwait(false);
|
||||||
if (htmlDocument == null) {
|
if (htmlDocument == null) {
|
||||||
Bot.ArchiLogger.LogGenericDebug("Could not get discovery queue page, returning null");
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
HtmlNode htmlNode = htmlDocument.DocumentNode.SelectSingleNode("//div[@class='subtext']");
|
HtmlNode htmlNode = htmlDocument.DocumentNode.SelectSingleNode("//div[@class='subtext']");
|
||||||
if (htmlNode == null) {
|
if (htmlNode == null) {
|
||||||
Bot.ArchiLogger.LogNullError(nameof(htmlNode));
|
// No cards for exploring the queue available
|
||||||
return null;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
string text = htmlNode.InnerText;
|
string text = htmlNode.InnerText;
|
||||||
if (!string.IsNullOrEmpty(text)) {
|
if (!string.IsNullOrEmpty(text)) {
|
||||||
// It'd make more sense to check "Come back tomorrow", but it might not cover out-of-the-event queue
|
// It'd make more sense to check "Come back tomorrow", but it might not cover out-of-the-event queue
|
||||||
Bot.ArchiLogger.LogGenericDebug("Our text is: " + text);
|
|
||||||
return !text.StartsWith("You can get ", StringComparison.Ordinal);
|
return !text.StartsWith("You can get ", StringComparison.Ordinal);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -116,13 +130,11 @@ namespace ArchiSteamFarm {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("Getting SteamAwards page...");
|
|
||||||
HtmlDocument htmlDocument = await Bot.ArchiWebHandler.GetSteamAwardsPage().ConfigureAwait(false);
|
HtmlDocument htmlDocument = await Bot.ArchiWebHandler.GetSteamAwardsPage().ConfigureAwait(false);
|
||||||
|
|
||||||
HtmlNodeCollection nominationsNodes = htmlDocument?.DocumentNode.SelectNodes("//div[@class='vote_nominations store_horizontal_autoslider']");
|
HtmlNodeCollection nominationsNodes = htmlDocument?.DocumentNode.SelectNodes("//div[@class='vote_nominations store_horizontal_autoslider']");
|
||||||
if (nominationsNodes == null) {
|
if (nominationsNodes == null) {
|
||||||
// Event ended, error or likewise
|
// Event ended, error or likewise
|
||||||
Bot.ArchiLogger.LogGenericDebug("Could not get SteamAwards page, returning");
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -130,7 +142,6 @@ namespace ArchiSteamFarm {
|
|||||||
HtmlNode myVoteNode = nominationsNode.SelectSingleNode("./div[@class='vote_nomination your_vote']");
|
HtmlNode myVoteNode = nominationsNode.SelectSingleNode("./div[@class='vote_nomination your_vote']");
|
||||||
if (myVoteNode != null) {
|
if (myVoteNode != null) {
|
||||||
// Already voted
|
// Already voted
|
||||||
Bot.ArchiLogger.LogGenericDebug("We voted already, nothing to do");
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -167,10 +178,9 @@ namespace ArchiSteamFarm {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bot.ArchiLogger.LogGenericDebug("Voting in #" + voteID + " for " + appID + "...");
|
|
||||||
await Bot.ArchiWebHandler.SteamAwardsVote(voteID, appID).ConfigureAwait(false);
|
await Bot.ArchiWebHandler.SteamAwardsVote(voteID, appID).ConfigureAwait(false);
|
||||||
Bot.ArchiLogger.LogGenericDebug("Done!");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -31,7 +31,7 @@ using System.Text;
|
|||||||
|
|
||||||
namespace ArchiSteamFarm {
|
namespace ArchiSteamFarm {
|
||||||
internal static class Utilities {
|
internal static class Utilities {
|
||||||
private static readonly Random Random = new Random();
|
//private static readonly Random Random = new Random();
|
||||||
|
|
||||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||||
[SuppressMessage("ReSharper", "UnusedParameter.Global")]
|
[SuppressMessage("ReSharper", "UnusedParameter.Global")]
|
||||||
@@ -58,6 +58,7 @@ namespace ArchiSteamFarm {
|
|||||||
|
|
||||||
internal static uint GetUnixTime() => (uint) DateTimeOffset.Now.ToUnixTimeSeconds();
|
internal static uint GetUnixTime() => (uint) DateTimeOffset.Now.ToUnixTimeSeconds();
|
||||||
|
|
||||||
|
/*
|
||||||
internal static int RandomNext(int maxWithout) {
|
internal static int RandomNext(int maxWithout) {
|
||||||
if (maxWithout <= 0) {
|
if (maxWithout <= 0) {
|
||||||
Program.ArchiLogger.LogNullError(nameof(maxWithout));
|
Program.ArchiLogger.LogNullError(nameof(maxWithout));
|
||||||
@@ -72,6 +73,7 @@ namespace ArchiSteamFarm {
|
|||||||
return Random.Next(maxWithout);
|
return Random.Next(maxWithout);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
internal static string ToHumanReadable(this TimeSpan timeSpan) {
|
internal static string ToHumanReadable(this TimeSpan timeSpan) {
|
||||||
// It's really dirty, I'd appreciate a lot if C# offered nice TimeSpan formatting by default
|
// It's really dirty, I'd appreciate a lot if C# offered nice TimeSpan formatting by default
|
||||||
@@ -99,6 +101,15 @@ namespace ArchiSteamFarm {
|
|||||||
result.Append(',');
|
result.Append(',');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (timeSpan.Minutes > 0) {
|
||||||
|
result.Append(" " + timeSpan.Minutes + " minute");
|
||||||
|
if (timeSpan.Minutes > 1) {
|
||||||
|
result.Append('s');
|
||||||
|
}
|
||||||
|
|
||||||
|
result.Append(',');
|
||||||
|
}
|
||||||
|
|
||||||
if (timeSpan.Seconds > 0) {
|
if (timeSpan.Seconds > 0) {
|
||||||
result.Append(" " + timeSpan.Hours + " second");
|
result.Append(" " + timeSpan.Hours + " second");
|
||||||
if (timeSpan.Seconds > 1) {
|
if (timeSpan.Seconds > 1) {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -102,7 +102,7 @@ namespace ArchiSteamFarm {
|
|||||||
// We use SecurityMode.None for Mono compatibility
|
// We use SecurityMode.None for Mono compatibility
|
||||||
// Yes, also on Windows, for Mono<->Windows communication
|
// Yes, also on Windows, for Mono<->Windows communication
|
||||||
Security = { Mode = SecurityMode.None },
|
Security = { Mode = SecurityMode.None },
|
||||||
SendTimeout = new TimeSpan(0, 5, 0)
|
SendTimeout = new TimeSpan(0, 0, Program.GlobalConfig.HttpTimeout)
|
||||||
},
|
},
|
||||||
new EndpointAddress(URL)
|
new EndpointAddress(URL)
|
||||||
);
|
);
|
||||||
@@ -126,7 +126,7 @@ namespace ArchiSteamFarm {
|
|||||||
// We use SecurityMode.None for Mono compatibility
|
// We use SecurityMode.None for Mono compatibility
|
||||||
// Yes, also on Windows, for Mono<->Windows communication
|
// Yes, also on Windows, for Mono<->Windows communication
|
||||||
Security = { Mode = SecurityMode.None },
|
Security = { Mode = SecurityMode.None },
|
||||||
SendTimeout = new TimeSpan(0, 5, 0)
|
SendTimeout = new TimeSpan(0, 0, Program.GlobalConfig.HttpTimeout)
|
||||||
},
|
},
|
||||||
string.Empty
|
string.Empty
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -78,7 +78,8 @@ namespace ConfigGenerator {
|
|||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
public bool IsBotAccount { get; set; } = false;
|
public bool IsBotAccount { get; set; } = false;
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[Category("\tAdvanced")]
|
||||||
|
[JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)]
|
||||||
public List<Steam.Item.EType> LootableTypes { get; set; } = new List<Steam.Item.EType> { Steam.Item.EType.BoosterPack, Steam.Item.EType.FoilTradingCard, Steam.Item.EType.TradingCard };
|
public List<Steam.Item.EType> LootableTypes { get; set; } = new List<Steam.Item.EType> { Steam.Item.EType.BoosterPack, Steam.Item.EType.FoilTradingCard, Steam.Item.EType.TradingCard };
|
||||||
|
|
||||||
[Category("\tAccess")]
|
[Category("\tAccess")]
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@@ -53,8 +53,8 @@ namespace ConfigGenerator {
|
|||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
public bool AutoUpdates { get; set; } = true;
|
public bool AutoUpdates { get; set; } = true;
|
||||||
|
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)]
|
||||||
public List<uint> Blacklist { get; set; } = new List<uint>();
|
public List<uint> Blacklist { get; set; } = new List<uint>(GlobalBlacklist);
|
||||||
|
|
||||||
[Category("\tDebugging")]
|
[Category("\tDebugging")]
|
||||||
[JsonProperty(Required = Required.DisallowNull)]
|
[JsonProperty(Required = Required.DisallowNull)]
|
||||||
@@ -126,7 +126,6 @@ namespace ConfigGenerator {
|
|||||||
throw new ArgumentNullException(nameof(filePath));
|
throw new ArgumentNullException(nameof(filePath));
|
||||||
}
|
}
|
||||||
|
|
||||||
Blacklist.AddRange(GlobalBlacklist);
|
|
||||||
Save();
|
Save();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
/ ___ \ | | | (__ | | | || | ___) || |_| __/| (_| || | | | | || _|| (_| || | | | | | | |
|
||||||
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
/_/ \_\|_| \___||_| |_||_||____/ \__|\___| \__,_||_| |_| |_||_| \__,_||_| |_| |_| |_|
|
||||||
|
|
||||||
Copyright 2015-2016 Łukasz "JustArchi" Domeradzki
|
Copyright 2015-2017 Łukasz "JustArchi" Domeradzki
|
||||||
Contact: JustArchi@JustArchi.net
|
Contact: JustArchi@JustArchi.net
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
|||||||
@@ -187,7 +187,7 @@
|
|||||||
same "printed page" as the copyright notice for easier
|
same "printed page" as the copyright notice for easier
|
||||||
identification within third-party archives.
|
identification within third-party archives.
|
||||||
|
|
||||||
Copyright 2015 Łukasz "JustArchi" Domeradzki
|
Copyright [yyyy] [name of copyright owner]
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
you may not use this file except in compliance with the License.
|
you may not use this file except in compliance with the License.
|
||||||
@@ -199,4 +199,4 @@
|
|||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
See the License for the specific language governing permissions and
|
See the License for the specific language governing permissions and
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
Reference in New Issue
Block a user