Updated string to mongoId
This commit is contained in:
@@ -209,11 +209,11 @@ namespace SPTarkov.Server.Core.Extensions
|
||||
/// <param name="rewardValue">The number of extra repeatables to add</param>
|
||||
public static void AddExtraRepeatableQuest(
|
||||
this SptProfile fullProfile,
|
||||
string repeatableId,
|
||||
MongoId repeatableId,
|
||||
double rewardValue
|
||||
)
|
||||
{
|
||||
fullProfile.SptData.ExtraRepeatableQuests ??= new Dictionary<string, double>();
|
||||
fullProfile.SptData.ExtraRepeatableQuests ??= new Dictionary<MongoId, double>();
|
||||
|
||||
if (!fullProfile.SptData.ExtraRepeatableQuests.TryAdd(repeatableId, 0))
|
||||
{
|
||||
|
||||
@@ -191,7 +191,10 @@ public class PrestigeHelper(
|
||||
}
|
||||
case RewardType.ExtraDailyQuest:
|
||||
{
|
||||
newProfile.AddExtraRepeatableQuest(reward.Target, (double)reward.Value);
|
||||
newProfile.AddExtraRepeatableQuest(
|
||||
new MongoId(reward.Target),
|
||||
(double)reward.Value
|
||||
);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
||||
@@ -214,11 +214,11 @@ public class ProfileHelper(
|
||||
Mods = [],
|
||||
ReceivedGifts = [],
|
||||
BlacklistedItemTemplates = [],
|
||||
FreeRepeatableRefreshUsedCount = new Dictionary<string, int>(),
|
||||
Migrations = new Dictionary<string, long>(),
|
||||
CultistRewards = new Dictionary<string, AcceptedCultistReward>(),
|
||||
FreeRepeatableRefreshUsedCount = new(),
|
||||
Migrations = new(),
|
||||
CultistRewards = new(),
|
||||
PendingPrestige = null,
|
||||
ExtraRepeatableQuests = new Dictionary<string, double>(),
|
||||
ExtraRepeatableQuests = new(),
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -446,7 +446,7 @@ public record Spt
|
||||
public PendingPrestige? PendingPrestige { get; set; }
|
||||
|
||||
[JsonPropertyName("extraRepeatableQuests")]
|
||||
public Dictionary<string, double>? ExtraRepeatableQuests { get; set; }
|
||||
public Dictionary<MongoId, double>? ExtraRepeatableQuests { get; set; }
|
||||
}
|
||||
|
||||
public record AcceptedCultistReward
|
||||
|
||||
Reference in New Issue
Block a user