Compare commits

...

1 Commits

Author SHA1 Message Date
DrakiaXYZ
3ec2ce789b - Update items.json from latest 3.10.0 server branch
- Add new bot types to BotType and Program.cs `botTypes` array
- Fix exceptions caused by items in bot pockets in GearChanceHelper
- Update PMCGenerator to target same .Net framework and Newtonsoft version to stop compilation errors
2024-10-31 21:56:07 -07:00
5 changed files with 472203 additions and 423523 deletions

View File

@ -53,7 +53,14 @@
pmcusec = 51,
skier = 52,
peacemaker = 53,
bosspartisan = 54
bosspartisan = 54,
sectantpredvestnik = 55,
sectantprizrak = 56,
sectantoni = 57,
infectedassault = 58,
infectedpmc = 59,
infectedcivil = 60,
infectedlaborant = 61,
infectedtagilla = 62
}
}

File diff suppressed because it is too large Load Diff

View File

@ -34,7 +34,8 @@ namespace Generator.Helpers.Gear
}
var template = ItemTemplateHelper.GetTemplateById(inventoryItem._tpl);
var parentTemplate = ItemTemplateHelper.GetTemplateById(baseBot.Inventory.items.Single(i => i._id == inventoryItem.parentId)._tpl);
var parentId = baseBot.Inventory.items.SingleOrDefault(i => i._id == inventoryItem.parentId)?._tpl;
var parentTemplate = parentId != null ? ItemTemplateHelper.GetTemplateById(parentId) : null;
if (!(parentTemplate?._props?.Slots?.FirstOrDefault(slot => slot._name == inventoryItem.slotId)?._required ?? false))
{
@ -111,7 +112,8 @@ namespace Generator.Helpers.Gear
}
var template = ItemTemplateHelper.GetTemplateById(inventoryItem._tpl);
var parentTemplate = ItemTemplateHelper.GetTemplateById(baseBot.Inventory.items.Single(i => i._id == inventoryItem.parentId)._tpl);
var parentId = baseBot.Inventory.items.SingleOrDefault(i => i._id == inventoryItem.parentId)?._tpl;
var parentTemplate = parentId != null ? ItemTemplateHelper.GetTemplateById(parentId) : null;
if (!(parentTemplate?._props?.Slots?.FirstOrDefault(slot => slot._name == inventoryItem.slotId)?._required ?? false))
{

View File

@ -60,7 +60,17 @@ internal static class Program
"spiritwinter",
"skier",
"peacemaker"
"peacemaker",
"sectantpredvestnik",
"sectantprizrak",
"sectantoni",
"infectedassault",
"infectedpmc",
"infectedcivil",
"infectedlaborant",
"infectedtagilla",
};
// Read raw bot dumps and turn into c# objects

View File

@ -2,11 +2,11 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
</ItemGroup>
<ItemGroup>