Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP #85

Merged
merged 1 commit into from
Oct 24, 2024
Merged

WIP #85

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Fuyu.Backend.BSG/DTO/Profiles/Profile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public class Profile
[DataMember]
public RagfairInfo RagfairInfo;

[DataMember]
[DataMember(EmitDefaultValue = false)]
public Dictionary<MongoId, TraderInfo> TradersInfo;

[DataMember]
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.BSG/DTO/Profiles/ProfileInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public class ProfileInfo
[DataMember]
public bool HasPveGame;

[DataMember]
[DataMember(EmitDefaultValue = false)]
public Ban[] Bans;
}
}
6 changes: 6 additions & 0 deletions Fuyu.Backend.EFT/Services/BotService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@ public static Profile[] GetBots(BotCondition[] conditions)

private static Profile GenerateBot(EBotRole role)
{
// TODO: remove this rimuru top 1 pls fix immediately
if (role == EBotRole.pmcBEAR || role == EBotRole.pmcUSEC)
{
role = EBotRole.assault;
}

var profile = Json.Parse<Profile>(_profiles[role]);

// regenerate all ids
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Services/ItemService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public static void RegenerateInventoryIds(InventoryInfo inventory)
if (inventory.stash != null)
{
mapping.Add(inventory.stash.Value, new MongoId(true));
inventory.equipment = mapping[inventory.stash.Value];
inventory.stash = mapping[inventory.stash.Value];
}

// regenerate inventory quest raid items
Expand Down