Compare commits

..

24 Commits

Author SHA1 Message Date
Vitaliya
7289f3bae4 Add blacklisting of AppIDs for MatchActively (#2183)
* Add blacklisting of AppIDs for MatchActively

* Add serialization and modification event
2021-02-16 19:30:16 +01:00
JustArchi
61873cfd72 Avoid complete purge on each PICS restart
There is no easy way for us to retrieve access tokens again without a full relog procedure, and those are needed for refresh of packages, which should also be optional due to excessive amount of PICS restarts emitted by Steam.

At worst, we'll just have outdated data until a full relog procedure, as opposed to having no data at all until relog procedure...
2021-02-16 19:27:00 +01:00
JustArchi
9c8fe06bfe Bump 2021-02-16 19:24:21 +01:00
JustArchi
47a90042a2 Misc 2021-02-16 09:27:15 +01:00
JustArchi
e56fb73997 Misc 2021-02-16 09:27:10 +01:00
GitHub Action
9ff55b69b3 Automatic translations update 2021-02-16 02:15:39 +00:00
dependabot-preview[bot]
023b159c32 Bump ASF-ui from c01f990 to 6c110b8
Bumps [ASF-ui](https://github.com/JustArchiNET/ASF-ui) from `c01f990` to `6c110b8`.
- [Release notes](https://github.com/JustArchiNET/ASF-ui/releases)
- [Commits](c01f9900f5...6c110b8e16)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-16 01:30:55 +00:00
dependabot-preview[bot]
42f0692d8c Bump ASF-ui from 7869ac6 to c01f990
Bumps [ASF-ui](https://github.com/JustArchiNET/ASF-ui) from `7869ac6` to `c01f990`.
- [Release notes](https://github.com/JustArchiNET/ASF-ui/releases)
- [Commits](7869ac68fe...c01f9900f5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-15 01:43:49 +00:00
dependabot-preview[bot]
1c13b89e6f Bump Swashbuckle.AspNetCore.Newtonsoft from 6.0.4 to 6.0.5
Bumps [Swashbuckle.AspNetCore.Newtonsoft](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.4 to 6.0.5.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.4...v6.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-13 18:00:17 +00:00
dependabot-preview[bot]
7c5bf81e24 Bump Swashbuckle.AspNetCore.Annotations from 6.0.4 to 6.0.5
Bumps [Swashbuckle.AspNetCore.Annotations](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.4 to 6.0.5.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.4...v6.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-13 13:39:36 +00:00
dependabot-preview[bot]
52547ee3d9 Bump Swashbuckle.AspNetCore from 6.0.4 to 6.0.5
Bumps [Swashbuckle.AspNetCore](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.4 to 6.0.5.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.4...v6.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-13 12:40:00 +00:00
GitHub Action
74d5ddaba7 Automatic translations update 2021-02-12 02:14:50 +00:00
dependabot-preview[bot]
29c8f408b5 Bump ASF-ui from a5989bc to 7869ac6
Bumps [ASF-ui](https://github.com/JustArchiNET/ASF-ui) from `a5989bc` to `7869ac6`.
- [Release notes](https://github.com/JustArchiNET/ASF-ui/releases)
- [Commits](a5989bcc1c...7869ac68fe)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-12 01:31:19 +00:00
GitHub Action
0697e49011 Automatic translations update 2021-02-11 02:14:30 +00:00
dependabot-preview[bot]
dff6a8aca2 Bump ASF-ui from 7040199 to a5989bc
Bumps [ASF-ui](https://github.com/JustArchiNET/ASF-ui) from `7040199` to `a5989bc`.
- [Release notes](https://github.com/JustArchiNET/ASF-ui/releases)
- [Commits](7040199856...a5989bcc1c)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-11 01:31:14 +00:00
dependabot-preview[bot]
f9bd230ca2 Bump Swashbuckle.AspNetCore from 6.0.3 to 6.0.4
Bumps [Swashbuckle.AspNetCore](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.3 to 6.0.4.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.3...v6.0.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-11 00:04:47 +00:00
dependabot-preview[bot]
b4a0ecdcff Bump Swashbuckle.AspNetCore.Annotations from 6.0.3 to 6.0.4
Bumps [Swashbuckle.AspNetCore.Annotations](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.3 to 6.0.4.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.3...v6.0.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 23:16:02 +00:00
dependabot-preview[bot]
32429ab687 Bump Swashbuckle.AspNetCore.Newtonsoft from 6.0.3 to 6.0.4
Bumps [Swashbuckle.AspNetCore.Newtonsoft](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.3 to 6.0.4.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.3...v6.0.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 22:13:03 +00:00
dependabot-preview[bot]
fd343c56d5 Bump Swashbuckle.AspNetCore.Annotations from 6.0.2 to 6.0.3
Bumps [Swashbuckle.AspNetCore.Annotations](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.2 to 6.0.3.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.2...v6.0.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 16:52:11 +00:00
dependabot-preview[bot]
fe7cd72f13 Bump Swashbuckle.AspNetCore.Newtonsoft from 6.0.2 to 6.0.3
Bumps [Swashbuckle.AspNetCore.Newtonsoft](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.2 to 6.0.3.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.2...v6.0.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 16:02:19 +00:00
dependabot-preview[bot]
fcd3a469bc Bump Swashbuckle.AspNetCore from 6.0.2 to 6.0.3
Bumps [Swashbuckle.AspNetCore](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.0.2 to 6.0.3.
- [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases)
- [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.0.2...v6.0.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 14:56:24 +00:00
GitHub Action
4388fb7dcf Automatic translations update 2021-02-10 02:10:53 +00:00
dependabot-preview[bot]
45b87a1272 Bump ASF-ui from 3b3eaca to 7040199
Bumps [ASF-ui](https://github.com/JustArchiNET/ASF-ui) from `3b3eaca` to `7040199`.
- [Release notes](https://github.com/JustArchiNET/ASF-ui/releases)
- [Commits](3b3eaca810...7040199856)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-10 01:39:32 +00:00
JustArchi
713d725e03 Bump 2021-02-09 18:02:25 +01:00
12 changed files with 215 additions and 39 deletions

2
ASF-ui

Submodule ASF-ui updated: 3b3eaca810...6c110b8e16

View File

@@ -18,9 +18,9 @@
<PackageReference Include="NLog" Version="4.7.7" />
<PackageReference Include="NLog.Web.AspNetCore" Version="4.10.0" />
<PackageReference Include="SteamKit2" Version="2.3.0" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.0.2" />
<PackageReference Include="Swashbuckle.AspNetCore.Annotations" Version="6.0.2" />
<PackageReference Include="Swashbuckle.AspNetCore.Newtonsoft" Version="6.0.2" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.0.5" />
<PackageReference Include="Swashbuckle.AspNetCore.Annotations" Version="6.0.5" />
<PackageReference Include="Swashbuckle.AspNetCore.Newtonsoft" Version="6.0.5" />
<PackageReference Include="System.Composition" Version="5.0.1" />
<PackageReference Include="System.Linq.Async" Version="5.0.0" />
</ItemGroup>

View File

@@ -514,7 +514,7 @@ namespace ArchiSteamFarm {
throw new ArgumentNullException(nameof(inventory));
}
if ((amountsToExtract == null) || (amountsToExtract.Count == 0) || amountsToExtract.Any(kv => kv.Value.SetsToExtract == 0)) {
if ((amountsToExtract == null) || (amountsToExtract.Count == 0) || amountsToExtract.Values.Any(kv => kv.SetsToExtract == 0)) {
throw new ArgumentNullException(nameof(amountsToExtract));
}

View File

@@ -42,6 +42,9 @@ namespace ArchiSteamFarm {
[JsonProperty(Required = Required.DisallowNull)]
internal readonly ConcurrentHashSet<uint> IdlingPriorityAppIDs = new();
[JsonProperty(Required = Required.DisallowNull)]
internal readonly ConcurrentHashSet<uint> MatchActivelyBlacklistedAppIDs = new();
internal uint GamesToRedeemInBackgroundCount {
get {
lock (GamesToRedeemInBackground) {
@@ -100,12 +103,14 @@ namespace ArchiSteamFarm {
BlacklistedFromTradesSteamIDs.OnModified += OnObjectModified;
IdlingBlacklistedAppIDs.OnModified += OnObjectModified;
IdlingPriorityAppIDs.OnModified += OnObjectModified;
MatchActivelyBlacklistedAppIDs.OnModified += OnObjectModified;
}
public override void Dispose() {
BlacklistedFromTradesSteamIDs.OnModified -= OnObjectModified;
IdlingBlacklistedAppIDs.OnModified -= OnObjectModified;
IdlingPriorityAppIDs.OnModified -= OnObjectModified;
MatchActivelyBlacklistedAppIDs.OnModified -= OnObjectModified;
BackingMobileAuthenticator?.Dispose();
@@ -211,6 +216,7 @@ namespace ArchiSteamFarm {
public bool ShouldSerializeGamesToRedeemInBackground() => HasGamesToRedeemInBackground;
public bool ShouldSerializeIdlingBlacklistedAppIDs() => IdlingBlacklistedAppIDs.Count > 0;
public bool ShouldSerializeIdlingPriorityAppIDs() => IdlingPriorityAppIDs.Count > 0;
public bool ShouldSerializeMatchActivelyBlacklistedAppIDs() => MatchActivelyBlacklistedAppIDs.Count > 0;
// ReSharper restore UnusedMember.Global
}

View File

@@ -112,6 +112,8 @@ namespace ArchiSteamFarm {
return ResponseIdleBlacklist(steamID);
case "IQ":
return ResponseIdleQueue(steamID);
case "MAB":
return ResponseMatchActivelyBlacklist(steamID);
case "LEVEL":
return await ResponseLevel(steamID).ConfigureAwait(false);
case "LOOT":
@@ -221,6 +223,16 @@ namespace ArchiSteamFarm {
return await ResponseLootByRealAppIDs(steamID, args[1], Utilities.GetArgsAsText(args, 2, ","), true).ConfigureAwait(false);
case "LOOT%":
return await ResponseLootByRealAppIDs(steamID, args[1], true).ConfigureAwait(false);
case "MAB":
return await ResponseMatchActivelyBlacklist(steamID, Utilities.GetArgsAsText(args, 1, ",")).ConfigureAwait(false);
case "MABADD" when args.Length > 2:
return await ResponseMatchActivelyBlacklistAdd(steamID, args[1], Utilities.GetArgsAsText(args, 2, ",")).ConfigureAwait(false);
case "MABADD":
return ResponseMatchActivelyBlacklistAdd(steamID, args[1]);
case "MABRM" when args.Length > 2:
return await ResponseMatchActivelyBlacklistRemove(steamID, args[1], Utilities.GetArgsAsText(args, 2, ",")).ConfigureAwait(false);
case "MABRM":
return ResponseMatchActivelyBlacklistRemove(steamID, args[1]);
case "NICKNAME" when args.Length > 2:
return await ResponseNickname(steamID, args[1], Utilities.GetArgsAsText(message, 2)).ConfigureAwait(false);
case "NICKNAME":
@@ -1813,6 +1825,160 @@ namespace ArchiSteamFarm {
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
private string? ResponseMatchActivelyBlacklist(ulong steamID) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
return !Bot.HasAccess(steamID, BotConfig.EAccess.Master) ? null : FormatBotResponse(Bot.BotDatabase.MatchActivelyBlacklistedAppIDs.Count == 0 ? string.Format(CultureInfo.CurrentCulture, Strings.ErrorIsEmpty, nameof(Bot.BotDatabase.MatchActivelyBlacklistedAppIDs)) : string.Join(", ", Bot.BotDatabase.MatchActivelyBlacklistedAppIDs));
}
private static async Task<string?> ResponseMatchActivelyBlacklist(ulong steamID, string botNames) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
if (string.IsNullOrEmpty(botNames)) {
throw new ArgumentNullException(nameof(botNames));
}
HashSet<Bot>? bots = Bot.GetBots(botNames);
if ((bots == null) || (bots.Count == 0)) {
return ASF.IsOwner(steamID) ? FormatStaticResponse(string.Format(CultureInfo.CurrentCulture, Strings.BotNotFound, botNames)) : null;
}
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklist(steamID)))).ConfigureAwait(false);
List<string> responses = new(results.Where(result => !string.IsNullOrEmpty(result))!);
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
private string? ResponseMatchActivelyBlacklistAdd(ulong steamID, string targetAppIDs) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
if (string.IsNullOrEmpty(targetAppIDs)) {
throw new ArgumentNullException(nameof(targetAppIDs));
}
if (!Bot.HasAccess(steamID, BotConfig.EAccess.Master)) {
return null;
}
string[] targets = targetAppIDs.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
if (targets.Length == 0) {
return FormatBotResponse(string.Format(CultureInfo.CurrentCulture, Strings.ErrorIsEmpty, nameof(targets)));
}
HashSet<uint> appIDs = new();
foreach (string target in targets) {
if (!uint.TryParse(target, out uint appID) || (appID == 0)) {
return FormatBotResponse(string.Format(CultureInfo.CurrentCulture, Strings.ErrorParsingObject, nameof(appID)));
}
appIDs.Add(appID);
}
if (!Bot.BotDatabase.IdlingBlacklistedAppIDs.AddRange(appIDs)) {
return FormatBotResponse(Strings.NothingFound);
}
return FormatBotResponse(Strings.Done);
}
private static async Task<string?> ResponseMatchActivelyBlacklistAdd(ulong steamID, string botNames, string targetAppIDs) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
if (string.IsNullOrEmpty(botNames)) {
throw new ArgumentNullException(nameof(botNames));
}
if (string.IsNullOrEmpty(targetAppIDs)) {
throw new ArgumentNullException(nameof(targetAppIDs));
}
HashSet<Bot>? bots = Bot.GetBots(botNames);
if ((bots == null) || (bots.Count == 0)) {
return ASF.IsOwner(steamID) ? FormatStaticResponse(string.Format(CultureInfo.CurrentCulture, Strings.BotNotFound, botNames)) : null;
}
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklistAdd(steamID, targetAppIDs)))).ConfigureAwait(false);
List<string> responses = new(results.Where(result => !string.IsNullOrEmpty(result))!);
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
private string? ResponseMatchActivelyBlacklistRemove(ulong steamID, string targetAppIDs) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
if (string.IsNullOrEmpty(targetAppIDs)) {
throw new ArgumentNullException(nameof(targetAppIDs));
}
if (!Bot.HasAccess(steamID, BotConfig.EAccess.Master)) {
return null;
}
string[] targets = targetAppIDs.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
if (targets.Length == 0) {
return FormatBotResponse(string.Format(CultureInfo.CurrentCulture, Strings.ErrorIsEmpty, nameof(targets)));
}
HashSet<uint> appIDs = new();
foreach (string target in targets) {
if (!uint.TryParse(target, out uint appID) || (appID == 0)) {
return FormatBotResponse(string.Format(CultureInfo.CurrentCulture, Strings.ErrorParsingObject, nameof(appID)));
}
appIDs.Add(appID);
}
if (!Bot.BotDatabase.IdlingBlacklistedAppIDs.RemoveRange(appIDs)) {
return FormatBotResponse(Strings.NothingFound);
}
return FormatBotResponse(Strings.Done);
}
private static async Task<string?> ResponseMatchActivelyBlacklistRemove(ulong steamID, string botNames, string targetAppIDs) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));
}
if (string.IsNullOrEmpty(botNames)) {
throw new ArgumentNullException(nameof(botNames));
}
if (string.IsNullOrEmpty(targetAppIDs)) {
throw new ArgumentNullException(nameof(targetAppIDs));
}
HashSet<Bot>? bots = Bot.GetBots(botNames);
if ((bots == null) || (bots.Count == 0)) {
return ASF.IsOwner(steamID) ? FormatStaticResponse(string.Format(CultureInfo.CurrentCulture, Strings.BotNotFound, botNames)) : null;
}
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklistRemove(steamID, targetAppIDs)))).ConfigureAwait(false);
List<string> responses = new(results.Where(result => !string.IsNullOrEmpty(result))!);
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
private string? ResponseNickname(ulong steamID, string nickname) {
if ((steamID == 0) || !new SteamID(steamID).IsIndividualAccount) {
throw new ArgumentOutOfRangeException(nameof(steamID));

View File

@@ -178,32 +178,34 @@ namespace ArchiSteamFarm {
return result;
}
internal async Task OnPICSChangesRestart([NotNull] Bot bot, uint currentChangeNumber) {
if (bot == null) {
throw new ArgumentNullException(nameof(bot));
}
internal async Task OnPICSChangesRestart(uint currentChangeNumber) {
if (currentChangeNumber == 0) {
throw new ArgumentOutOfRangeException(nameof(currentChangeNumber));
}
if (Bot.Bots == null) {
throw new InvalidOperationException(nameof(Bot.Bots));
}
if (currentChangeNumber <= LastChangeNumber) {
return;
}
if (!PackagesData.IsEmpty) {
PackagesData.Clear();
}
if (!PackagesAccessTokens.IsEmpty) {
PackagesAccessTokens.Clear();
}
LastChangeNumber = currentChangeNumber;
if (bot.OwnedPackageIDs.Count > 0) {
await RefreshPackages(bot, bot.OwnedPackageIDs.Keys.ToDictionary(packageID => packageID, _ => uint.MinValue)).ConfigureAwait(false);
Bot? refreshBot = Bot.Bots.Values.FirstOrDefault(bot => bot.IsConnectedAndLoggedOn);
if (refreshBot == null) {
return;
}
Dictionary<uint, uint> packageIDs = Bot.Bots.Values.SelectMany(bot => bot.OwnedPackageIDs.Keys).ToDictionary(packageID => packageID, _ => currentChangeNumber);
if (packageIDs.Count == 0) {
return;
}
await RefreshPackages(refreshBot, packageIDs).ConfigureAwait(false);
}
internal void RefreshPackageAccessTokens(IReadOnlyDictionary<uint, ulong> packageAccessTokens) {
@@ -237,7 +239,7 @@ namespace ArchiSteamFarm {
await PackagesRefreshSemaphore.WaitAsync().ConfigureAwait(false);
try {
HashSet<uint> packageIDs = packages.Where(package => (package.Key != 0) && (!PackagesData.TryGetValue(package.Key, out (uint ChangeNumber, ImmutableHashSet<uint>? AppIDs) packageData) || (packageData.ChangeNumber < package.Value))).Select(package => package.Key).ToHashSet();
HashSet<uint> packageIDs = packages.Where(package => (package.Key != 0) && (!PackagesData.TryGetValue(package.Key, out (uint ChangeNumber, ImmutableHashSet<uint>? AppIDs) previousData) || (previousData.ChangeNumber < package.Value))).Select(package => package.Key).ToHashSet();
if (packageIDs.Count == 0) {
return;

View File

@@ -456,7 +456,7 @@ StackTrace:
<value>Proposta de troca enviada com sucesso!</value>
</data>
<data name="BotSendingTradeToYourself" xml:space="preserve">
<value>Você não pode enviar uma proposta de troca para você mesmo!</value>
<value>Você não pode propor uma troca a si mesmo!</value>
</data>
<data name="BotNoASFAuthenticator" xml:space="preserve">
<value>Este bot não possui o ASF 2FA habilitado! Você se esqueceu de importar o autenticador como ASF 2FA?</value>
@@ -480,11 +480,11 @@ StackTrace:
<value>Reconectando...</value>
</data>
<data name="BotRedeem" xml:space="preserve">
<value>Key: {0} | Estado: {1}</value>
<value>Código: {0} | Estado: {1}</value>
<comment>{0} will be replaced by cd-key (string), {1} will be replaced by status string</comment>
</data>
<data name="BotRedeemWithItems" xml:space="preserve">
<value>Key: {0} | Estado: {1} | Itens: {2}</value>
<value>Código: {0} | Estado: {1} | Itens: {2}</value>
<comment>{0} will be replaced by cd-key (string), {1} will be replaced by status string, {2} will be replaced by list of key-value pairs, separated by a comma</comment>
</data>
<data name="BotRemovedExpiredLoginKey" xml:space="preserve">
@@ -517,7 +517,7 @@ StackTrace:
<comment>{0} will be replaced by object's name</comment>
</data>
<data name="UnusedKeys" xml:space="preserve">
<value>Keys não utilizadas: {0}</value>
<value>Códigos não ativados: {0}</value>
<comment>{0} will be replaced by list of cd-keys (strings), separated by a comma</comment>
</data>
<data name="WarningFailedWithError" xml:space="preserve">
@@ -567,7 +567,7 @@ StackTrace:
<value>O valor de CurrentCulture fornecido é inválido, o ASF continuará executando com o valor padrão!</value>
</data>
<data name="TranslationIncomplete" xml:space="preserve">
<value>O ASF tentará usar seu idioma {0} preferencial, mas a tradução para este idioma só está {1} concluída. Talvez você possa nos ajudar a melhorar a tradução do ASF para o seu idioma?</value>
<value>O ASF tentará usar o seu idioma preferido, {0}, mas a tradução para este idioma só está {1} concluída. Talvez você possa nos ajudar a melhorar a tradução do ASF para o seu idioma?</value>
<comment>{0} will be replaced by culture code, such as "en-US", {1} will be replaced by completeness percentage, such as "78.5%"</comment>
</data>
<data name="IdlingGameNotPossible" xml:space="preserve">
@@ -599,7 +599,7 @@ StackTrace:
<value>Acesso negado!</value>
</data>
<data name="WarningPreReleaseVersion" xml:space="preserve">
<value>Você está usando uma versão que é mais nova que a última lançada para o seu canal de atualizações. Tenha em mente que versões de pré-lançamento são indicadas a usuários que sabem como relatar bugs, lidar com problemas e dar feedback - nenhum apoio técnico será fornecido.</value>
<value>Você está usando uma versão que é mais nova que a última lançada para o seu canal de atualizações. Tenha em mente que versões de pré-lançamento são dedicadas a usuários que sabem como relatar bugs, lidar com problemas e dar feedback - nenhum apoio técnico será fornecido.</value>
</data>
<data name="BotStats" xml:space="preserve">
<value>Uso de memória atual: {0} MB.
@@ -648,11 +648,11 @@ Tempo de execução: {1}</value>
<comment>{0} will be replaced by bot's level</comment>
</data>
<data name="ActivelyMatchingItems" xml:space="preserve">
<value>Correspondendo itens Steam, rodada #{0}...</value>
<value>Associando itens do Steam, {0}ª rodada...</value>
<comment>{0} will be replaced by round number</comment>
</data>
<data name="DoneActivelyMatchingItems" xml:space="preserve">
<value>Itens Steam correspondidos, rodada #{0}.</value>
<value>Associação de itens do Steam concluída, {0}ª rodada.</value>
<comment>{0} will be replaced by round number</comment>
</data>
<data name="ErrorAborted" xml:space="preserve">
@@ -678,7 +678,7 @@ Tempo de execução: {1}</value>
<value>Nada encontrado!</value>
</data>
<data name="PluginsWarning" xml:space="preserve">
<value>Você carregou um ou mais plugins personalizados no ASF. Como não podemos oferecer suporte para configurações modificadas contate os desenvolvedores do plugin que você decidiu usar em caso de problemas.</value>
<value>Você carregou um ou mais plugins personalizados no ASF. Como não podemos oferecer suporte para configurações modificadas, você precisará entrar em contato com os desenvolvedores do plugin caso enfrente algum problema.</value>
</data>
<data name="PleaseWait" xml:space="preserve">
<value>Aguarde...</value>
@@ -725,7 +725,7 @@ Tempo de execução: {1}</value>
<value>A configuração IPC foi alterada!</value>
</data>
<data name="BotTradeOfferResult" xml:space="preserve">
<value>A oferta de troca {0} retornou o valor {1} devido às configurações: {2}.</value>
<value>A proposta de troca {0} retornou o valor {1} devido às configurações: {2}.</value>
<comment>{0} will be replaced by trade offer ID (number), {1} will be replaced by internal ASF enum name, {2} will be replaced by technical reason why the trade was determined to be in this state</comment>
</data>
<data name="BotInvalidPasswordDuringLogin" xml:space="preserve">
@@ -743,6 +743,6 @@ Tempo de execução: {1}</value>
<value>Argumento de linha de comando desconhecido: {0}</value>
</data>
<data name="ErrorConfigDirectoryNotFound" xml:space="preserve">
<value>Diretório da configuração não encontrado, abortando!</value>
<value>Diretório de configuração não encontrado, abortando!</value>
</data>
</root>

View File

@@ -323,7 +323,7 @@
<comment>{0} will be replaced by list of the games (IDs, numbers), separated by a comma</comment>
</data>
<data name="IdlingStatusForGame" xml:space="preserve">
<value>Статус фарма для {0} ({1}): {2} карты осталось</value>
<value>Статус фарма для {0} ({1}): {2} карт(ы) осталось</value>
<comment>{0} will be replaced by game's ID (number), {1} will be replaced by game's name, {2} will be replaced by number of cards left to idle</comment>
</data>
<data name="IdlingStopped" xml:space="preserve">
@@ -455,7 +455,9 @@
<data name="BotLootingSuccess" xml:space="preserve">
<value>Предложение обмена отправлено!</value>
</data>
<data name="BotSendingTradeToYourself" xml:space="preserve">
<value>Невозможно отправить обмен самому себе!</value>
</data>
<data name="BotNoASFAuthenticator" xml:space="preserve">
<value>У этого бота не включён ASF 2FA! Вы не забыли импортировать свой аутентификатор в ASF 2FA?</value>
</data>

View File

@@ -366,7 +366,7 @@ namespace ArchiSteamFarm {
HashSet<Steam.Asset> ourInventory;
try {
ourInventory = await Bot.ArchiWebHandler.GetInventoryAsync().Where(item => acceptedMatchableTypes.Contains(item.Type)).ToHashSetAsync().ConfigureAwait(false);
ourInventory = await Bot.ArchiWebHandler.GetInventoryAsync().Where(item => acceptedMatchableTypes.Contains(item.Type) && !Bot.BotDatabase.MatchActivelyBlacklistedAppIDs.Contains(item.RealAppID)).ToHashSetAsync().ConfigureAwait(false);
} catch (HttpRequestException e) {
Bot.ArchiLogger.LogGenericWarningException(e);

View File

@@ -65,7 +65,7 @@ namespace ArchiSteamFarm {
SteamApps.PICSChangesCallback? picsChanges = null;
for (byte i = 0; (i < WebBrowser.MaxTries) && (picsChanges == null); i++) {
refreshBot = Bot.Bots?.Values.Where(bot => bot.IsConnectedAndLoggedOn).OrderByDescending(bot => bot.OwnedPackageIDs.Count).FirstOrDefault();
refreshBot = Bot.Bots?.Values.FirstOrDefault(bot => bot.IsConnectedAndLoggedOn);
if (refreshBot == null) {
LiveUpdate = false;
@@ -97,7 +97,7 @@ namespace ArchiSteamFarm {
if (picsChanges.RequiresFullAppUpdate || picsChanges.RequiresFullPackageUpdate || ((picsChanges.AppChanges.Count == 0) && (picsChanges.PackageChanges.Count == 0))) {
if (ASF.GlobalDatabase != null) {
await ASF.GlobalDatabase.OnPICSChangesRestart(refreshBot, picsChanges.CurrentChangeNumber).ConfigureAwait(false);
await ASF.GlobalDatabase.OnPICSChangesRestart(picsChanges.CurrentChangeNumber).ConfigureAwait(false);
}
LiveUpdate = true;

View File

@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<Version>5.0.3.2</Version>
<Version>5.0.4.0</Version>
</PropertyGroup>
<PropertyGroup>

2
wiki

Submodule wiki updated: 3eda3002a3...e899c6831e