Commit Graph

2074 Commits

Author SHA1 Message Date
Dev
f860642882 Add ability to adjust skill gain per skill when in menus via inventory config 2024-03-09 16:14:34 +00:00
Dev
5343f8982c Add IDEA rig to rig slots on PMCs 2024-03-09 11:49:20 +00:00
DrakiaXYZ
f95ed922a4 Fix quest statusTimers ending up with named keys (!254)
- Don't depend on status being non-numeric to fix statusTimers
- Cleaner tracking of fix counts in `updateProfileQuestDataValues`
- Better number checking for quest status, since `0` is a valid status, but fails the `!Number()` check
- Cleanup of quest status setting in `processAlteredQuests`

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/254
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-03-09 08:49:26 +00:00
Dev
75a8007842 Fix issue with PMC name causing formatting issues inside of client + lint 2024-03-09 08:44:40 +00:00
qe201020335
c17ab30d4d Add --arch and --platform options to NPM build commands to support cross-compiling (!247)
A previous commit 03ae37ec2f hardcoded windows x64 into the build options for build automation. This change restores the ability to build the server using the builder's architecture and platform to the default behavior and adds support for cross-compling via optional parameters `--arch` and `--platform`.

The option can be used by `npm run build:release -- --arch=x64 --platform=win32`.
Note the `--` in the middle is to tell npm whatever comes next, is for the script, not npm.

Additionally, the copy pnpm executables step has been changed to download pnpm release for the correct platform directly from the npm registry.

Co-authored-by: qe201020335 <qe201020335@sina.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/247
Co-authored-by: qe201020335 <qe201020335@noreply.dev.sp-tarkov.com>
Co-committed-by: qe201020335 <qe201020335@noreply.dev.sp-tarkov.com>
2024-03-08 18:11:04 +00:00
Dev
5ea7d7b97d Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-03-08 12:05:56 +00:00
Dev
92c5dc7f6b Reworked how items are chosen to be force-stacked
Fixes medical items not stacking correctly when there was multiple of the same item with different resource values

Added additional item types to be force-stacked
Added backpack item limit
Sligfhtly reduce item limit to account for items now stacking
2024-03-08 12:05:43 +00:00
DrakiaXYZ
56c0007caf Fix scav case timer not taking crafting skill into account (!252)
The assembly calculation for scav case timer first applies the player's crafting skill reduction, then multiplies by the resulting time by the Fence modifier:

```
return base.ReductionCoefficient * this.fenceTraderInfo_0.FenceLoyalty.ScavCaseTimeModifier;
```

This change makes the server calculation match this expected value

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/252
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-03-08 09:00:06 +00:00
DrakiaXYZ
77bc22f27e Fix being returned to the main menu when inventory full (!251)
- Add a new method of sending errors back but not flagging the response as failed in ItemEventCallback
- Don't treat `NOTENOUGHSPACE` errors as critical errors
- Return proper `NOTENOUGHSPACE` error code for stash space issues for trader/flea/craft
- Add missing error codes to `BackendErrorCodes`

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/251
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-03-08 08:59:14 +00:00
Cj
d4ee8f64d4 Implement IRelease interface, add new route action and data to core.json (!249)
This will need merged with: https://dev.sp-tarkov.com/SPT-AKI/Modules/pulls/90

Added
- IRelease interface
- betaDisclaimer: Beta text to be shown in the client
- betaDisclaimerTimeoutDelay: delay before the client exits if `OK` isnt pressed
- releaseSummary: a place to add release notes shown on first run, or if version has changed.

- new route for the client to request beta and changelog information

Im not the most familiar with the server, so if any of this needs moved to a different class or a new class made for it, ping me and let me know and I'll adjust it accordingly.

Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/249
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-07 18:16:55 +00:00
Dev
b79fc89d11 Filter out seasonal items from scavcase rewards when not inside seasonal event 2024-03-07 18:15:42 +00:00
Dev
f439f5888b Fix warning being logged constantly 2024-03-07 13:44:43 +00:00
Dev
479898ecab Centralise check for upd object / creation if it doesnt exist into one helper function inside ItemHelper
Some minor formatting updates
2024-03-07 09:18:39 +00:00
DrakiaXYZ
246f0d5030 Fix give command not working on armor presets and not marking presets as FiR (!250)
- Commando `give` command now handles all presets in the same way, so if BSG adds new types of presets in the future they should be supported without changes
- Commando `give` command now marks all given items as FiR for consistency

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/250
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-03-07 08:43:15 +00:00
Dev
c0ae34052b Made basic melee weapons more common on low level PMCs 2024-03-06 21:49:38 +00:00
Dev
9b07a11a1b Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-03-06 21:38:12 +00:00
Dev
5e3d7e457d Add additional item types to fence always-stack array
Adjust code to filter out all wearable equipment that has slots
Add +1 to items that are always-stackable - ensures items that have no key in `itemStackSizeOverrideMinMax` get incremented
2024-03-06 21:38:00 +00:00
Cj
2249337a02 Small optimization (!248)
Change `foreach` to use `for of` instead, `for of` is faster than `foreach`

Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/248
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-06 19:50:45 +00:00
Dev
96bace1288 Remove unused property from interface 2024-03-06 18:38:43 +00:00
Cj
4da70b80d3 Implement keeping pocket items on death to LostOnDeath.json configuration (!246)
Addresses: https://dev.sp-tarkov.com/SPT-AKI/Issues/issues/443

Re-added the ability to keep pocket items on death. The reason for the naming is to not confuse the root `Pockets` item. Where as `PocketItems` is a better descriptive fit for the behaviour.

New property in lostondeath.json -> `equipment.PocketItems` default `true` to discard items in pockets as normal on death.

Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/246
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-06 08:50:04 +00:00
Refringe
03ae37ec2f
Hardcoded Build Platform and Architecture
When the server was being built on systems other than Windows, that system's version of node was being downloaded for the build instead of the expected versions (Win/x64). This change hardcodes the values so that they're no longer dynamically pulled from the current system. Should help with generating automated builds.

Also, re-enabled the build step that added the icon to the Windows executable. It was being skipped over on non-Windows platforms and I don't know why... it should be a cross-platform solution.
2024-03-05 17:04:26 -05:00
Dev
570a81ff78 Show commit hash on debug and release versions 2024-03-05 20:23:10 +00:00
Dev
3846363758 Added system to weight stack size of money in bot inventories
Removed `dynamicLoot` system from pmc config as its been replaced with this one

#546
2024-03-05 12:24:09 +00:00
Dev
095fcf08fd Expand fence item force stacking system
Remove redundant multi-stack tracking system
Expand `getSingleItemStackCount()` to check for parent ids too
2024-03-05 10:43:47 +00:00
Dev
8f4df131ac Make use of itemHelper.isOfBaseclasses() inside duplicate fence offer check
Can now handle items that have a blacklisted grandparent
2024-03-05 08:52:21 +00:00
Cj
0740a84f6f [Enhancement] Ability to prevent duplicate fence offers by parentId (!245)
In relation to this QoL issue: https://dev.sp-tarkov.com/SPT-AKI/Issues/issues/547

This PR allows us to prevent fence selling duplicate items by parentId.

It adds a new property to `trader.json` `fence.preventDuplicateOffersOfCategory` its an array that takes parentIds. The scope of this PR only extends to ammo and ammo boxes. It can be expanded upon in the future with no code changes should the need arise.

The reason for this change is because currently fence can have duplicate stacks of identical ammo with different prices, which makes no sense. If you have any questions feel free to ping me on discord.

Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/245
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-05 08:49:10 +00:00
Dev
e3f341416d Add missing property to default profile templates 2024-03-04 21:39:10 +00:00
Dev
f0c589ff8e Update trader assorts 2024-03-04 21:27:25 +00:00
Dev
7a6422932b Update achievement json 2024-03-04 21:17:43 +00:00
Dev
5406bf0f07 Update quests data
Capturing outposts has a condition change, can now be done in zone "prapor_27_3" only, not 4
Missing informant had its available for finish conditions altered + has a new visibility condition
2024-03-04 21:15:28 +00:00
Dev
0c206385f1 Add missing nvgIsActiveChanceX values for cursed assault bots 2024-03-04 20:48:15 +00:00
Dev
63d5da4c18 Wallet loot improvements:
Added % chance to have loot to config
Added currency added weigfht system to config (only roubles by default)
Added allowed wallet types array to config
Added WZ wallet to pool of wallets to add money to

Fixed bug where itemCount type was incorrect
2024-03-04 20:18:53 +00:00
Cj
534e9d2ba1 [Enhancement] Custom flea category blacklist (!244)
Allows modders to blacklist entire categories from ragfair in relation to https://dev.sp-tarkov.com/SPT-AKI/Issues/issues/525

new properties under `RagfairConfig.dynamic.blacklist`
`enableCustomItemCategoryList` - this enables the custom custom category blacklist
`customItemCategoryList` - this is an array to take a list of parent id's

I tested it to confirm its working, will need some further testing.

Co-authored-by: Corey <dirtbikercj@gmail.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/244
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-04 19:36:31 +00:00
Cj
c7a577d903 Use globals ratingSumForIncrease value (!243)
Corrects previous pull request hardcoding the value for `ratingSumForIncrease`.

Anytime it changes in globals it will now be reflected without needing to change it in `RagFairOfferHelper`

Co-authored-by: Corey <dirtbikercj@gmail.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/243
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-04 18:06:10 +00:00
Dev
45687b982a Add empty ravangezryachiyevent object to item limits in config 2024-03-04 18:03:30 +00:00
Cj
9bd9ad30c0 Divide ratingInceaseCount by 100000 (!242)
Should address massive flea rep gains. Tested about 10 cases, all seem within expected range.

Divided ratingIncreaseCount by a factor of 100000

Co-authored-by: Corey <dirtbikercj@gmail.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/242
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-03-04 17:16:34 +00:00
Dev
a5de871c92 Added seasonal item handling inside daily quest reward generation code 2024-03-04 17:13:36 +00:00
Dev
52ebdf7483 Adjust various scav item type weights 2024-03-04 12:43:34 +00:00
Dev
85ac332beb Add gp-7 mask to PMCs 2024-03-03 11:28:02 +00:00
Dev
b1dad6d76f Adjust facecover chance for PMCs at level 23+ 2024-03-03 11:22:44 +00:00
chomp
9a28e86261 Fix incorrect trader messages being sent when dealing with insurance on labs (!241)
Co-authored-by: HiddenCirno <hiddencirno@noreply.dev.sp-tarkov.com>
Co-authored-by: Dev <dev@dev.sp-tarkov.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/241
2024-03-03 11:06:33 +00:00
Dev
d828e9da7d Revert change made to increaseProfileRagfairRating() 2024-03-02 20:12:40 +00:00
Dev
2e572ecf28 Add package-lock.json to repo 2024-03-02 19:42:49 +00:00
Dev
09d28440c9 Limit Gingy keychain to 1 per assault/marksman bot 2024-03-02 19:07:06 +00:00
Dev
b618381b74 Adjusted low level bot equipment weights
Added 2 backpacks to PMCs
Added 1 helmet to PMCs
2024-03-02 16:25:33 +00:00
Dev
f43504a097 Adjust scav drug chances 2024-03-02 14:17:44 +00:00
Dev
ae3b8e07bd Reduce carExtractBaseStandingGain to 0.2 2024-03-01 16:52:11 +00:00
Dev
7e3dc9156a Update englsih locale 2024-03-01 16:48:19 +00:00
Dev
a09e3e267b Update loot data for Backup hideout key 2024-03-01 16:31:59 +00:00
Dev
767063d291 Adjust water_collector total craft time every update() to include the players current CRAFTINGskill level instead of the first time profile is created
Refactored `registerProduction()` to also use this code

Fix code that was getting value to 4dp, not 3dp
Skip doing work in `getHideoutManagementConsumptionBonus()` if hideoutMgmt skill is 0
2024-02-29 16:24:47 +00:00
Dev
cfee4c10db Added additional soft insert slots to getSoftInsertSlotIds()
Fixes ronin face shield missing soft inserts
2024-02-29 12:24:32 +00:00
Dev
002279c787 Changed flea rep gain code to use globals data instead of ragfair json 2024-02-29 12:19:43 +00:00
Dev
c64e5f7239 Correct comment now power has changed 2024-02-28 22:34:07 +00:00
Dev
eee10407e8 Further changes to sell curve 2024-02-28 22:31:15 +00:00
Dev
5cbc4b7014 Improve sell chance % of player offers that are close to the average price 2024-02-28 22:24:58 +00:00
Dev
874463509a Remove unused base value from ragfair config 2024-02-28 21:37:42 +00:00
Dev
69bf8939d5 Add Optional chaining to registerProduction() to fix null error relating to crafts without tools 2024-02-28 20:33:10 +00:00
Dev
93411b8ce4 Adjust Caliber762x51 ammo for PMCs level 1-14 15-22 2024-02-28 19:03:48 +00:00
Dev
854670d4d5 Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-02-28 18:34:37 +00:00
Dev
3a301b02cc Handle when pscav kills a bot that doesnt have a json, default to 0 rep loss 2024-02-28 18:34:25 +00:00
DrakiaXYZ
4b8b62ae83 Utilize the release callback returned by lockFileSync to release the lock file (!239)
The error people are getting about a lock file already existing is due to `checkFileSync` returning false if the lock file is "stale".
The default "stale" timeout is 10 seconds, so if a save takes longer than this, the user will end up in a state where they can no longer save.

The documentation for `proper-lockfile` recommends using the callback returned by `lockFileSync` to remove the lock file, so I've switched to using this, and the error no longer occurs with long running save operations

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/239
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-02-28 07:56:53 +00:00
DrakiaXYZ
0433308fa8 Fix tools not coming back with the right properties after crafting (!238)
This resolves an issue where FiR tools were coming back as non-FiR. We now just store the whole .upd property, so any stats on the tool should carry over to after the craft is finished

Note: Will break any in-progress crafts that use tools

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/238
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-02-28 07:55:39 +00:00
phrisk
42782589e0 Return after returning player offers to avoid redundant remove offer following (!237)
#### Summary

> Should fix [Issue 523](https://dev.sp-tarkov.com/SPT-AKI/Issues/issues/523)

Tested a few different scenarios and the items were always correctly removed and returned to the player, however I did see the console warnings reported in the issue.

Both of the following call `this.ragfairOfferHandler.removeOffer(...)`:

 - `this.returnPlayerOffer(...)`
 - `this.removeOfferById(...)`

The latter logs a warning to the console because the offer is already removed when we reach that point.

This fix simply returns after the offer has been returned to the player, letting `returnPlayerOffer` deal with removing from the flea

Co-authored-by: phrisk <phrisk@phrisk.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/237
Co-authored-by: phrisk <phrisk@noreply.dev.sp-tarkov.com>
Co-committed-by: phrisk <phrisk@noreply.dev.sp-tarkov.com>
2024-02-27 23:45:47 +00:00
Dev
a1a5aa356a Add missing medical filter on backpack loot cache builder
remove hard coded 2 stim limit from assault
2024-02-27 23:44:23 +00:00
Dev
6ca9b23134 28965 2024-02-27 18:57:52 +00:00
Dev
bf317b6c2f updated setFindInRaidStatusForItem() to be protected + added return type
Improve comments inside `InventoryHelper`
2024-02-27 12:12:46 +00:00
Dev
3bc9833e57 Update getPlayerStashSize() to take into account bonus STASH_ROWS 2024-02-27 12:02:03 +00:00
Dev
32bca62272 Set place of fame hideout area to level 3 on dev profile 2024-02-27 11:34:44 +00:00
Dev
12afb8fccf Update map statics with new patch data 2024-02-27 10:50:43 +00:00
Dev
08f054bb53 Limit followerBully to 2 Drink items max 2024-02-27 10:49:34 +00:00
Dev
84616958c9 Limit Assault to 4 Medical items max 2024-02-27 10:03:03 +00:00
Dev
f53c637116 Limit followerkojaniy drink count to 2 max 2024-02-27 10:00:14 +00:00
Kaeno
afc8cc0385 Add ETSREWARD to gifts 2024-02-27 00:05:30 +00:00
Dev
7ec5d89608 Add ability to insert stash rows to profile 2024-02-26 23:51:45 +00:00
Dev
bde364388f Allow enabling snow in raid via SPT friend 2024-02-26 19:35:18 +00:00
Dev
51e1f7734e Add missing standing logging inside getFenceStandingChangeForKillAsScav() 2024-02-26 19:15:26 +00:00
Dev
47882e59d6 only show Found x insurance packages in profile in console, not log file 2024-02-26 18:24:45 +00:00
Dev
2bb85c8391 Adjust various weapons on PMCs between level 1-14 and 15-22 2024-02-26 17:45:55 +00:00
Dev
44e8378819 Properly match changes between usec/bear + adjust reserve map 2024-02-26 17:13:33 +00:00
Dev
f601f9e993 Various pmc changes:
Removed cursedassult brain
Lowered friendly PMC chance to 10%
Adjust streets/gz/shoreline brain weights
2024-02-26 17:06:52 +00:00
Dev
5ec38dae4f Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-02-26 17:02:46 +00:00
Dev
74297fa503 Adjust bot ammo weights for bots of level 1-14 and 15-22 2024-02-26 16:55:05 +00:00
Kaeno
3c113ddf7f Fixed ammobox breaking client + profile due to ragfair refresh adding extra ammo to ammo boxes 2024-02-26 16:32:56 +00:00
Dev
3c0471b288 Add ammo weights for PMCs between levels 15-22 2024-02-26 16:18:00 +00:00
Dev
9965c6cfe2 manually fix S&S Precision PlateFrame plate carrier (Goons Edition) getting new side plate slots 2024-02-26 12:32:21 +00:00
Dev
7c32bcbb9a Update JSONs 2024-02-26 12:28:29 +00:00
Dev
c7bbb97499 Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-02-26 11:27:00 +00:00
Dev
4e073baaca 28875 2024-02-26 11:26:50 +00:00
DrakiaXYZ
1deb6d9488 Add trader service requirement support & LKS Service requirements (!235)
Add LightKeeper trader service requirements

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/235
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-02-25 20:18:54 +00:00
Dev
40b31e1fe0 improved initialize() inside PresetController 2024-02-25 11:54:13 +00:00
Dev
a5450c6552 Moved addItemWithChildrenToEquipmentSlot() from BotWeaponGeneratorHelper to botGeneratorHelper 2024-02-25 11:45:34 +00:00
Dev
5f8b0592cc Updated foldItem() to use a .find() call instead of looping over all inventory items 2024-02-25 11:43:49 +00:00
Dev
2839ce8c77 Merge branch '3.8.0' of https://dev.sp-tarkov.com/SPT-AKI/Server into 3.8.0 2024-02-25 11:18:01 +00:00
Dev
1dda9efbd7 Move ExhaustableArray into its own file + make it implement interface 2024-02-25 11:17:33 +00:00
DrakiaXYZ
2adbb6a5fe Properly take and return tools when crafting (!234)
When starting a craft, tools are now taken, and the templateId is stored in the production in the user profile
When finishing a craft, space for both the tools and crafted item is verified, then both are added to the player stash correctly flagged as non-FiR and FiR respectively

Included a bit of code cleanup/reorg in areas I was working in

A few assumptions were made:
- Tools are expected to be single items, not stacks of an item (productions.json doesn't include a count property for tools, so this seems safe)
- Tools will never be a preset or have child items
- That the `canPlaceItemsInInventory` method over a concatenation of the tools and crafted item(s) will result in the same result as calling it individually over the two collections of items individually

Will need tested once merged into 380, I did basic testing, but there's a lot of different crafts that require tools

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/234
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-02-25 08:53:57 +00:00
DrakiaXYZ
19013a478f If a preset has a different _id property than its object key, output an error and skip it. (!233)
This resolves an issue where a mod with bad preset data is able to break loot generation

Can be tested by changing the "\_id" property of an item preset in globals.json, and seeing the error output to the console.

A better solution for the future may be to deprecate the "\_id" property entirely, and use just the object key, however that would have more far reaching changes compared to this simple fix

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/233
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
2024-02-24 23:26:27 +00:00
Dev
946dc52f1a Add Stim limit of 2 to assault bots 2024-02-23 16:37:56 +00:00
Dev
b5cde813a3 Cleanup of date calculation code 2024-02-23 16:10:18 +00:00
Dev
386aeee9d7 Updated server to match raid times with live 2024-02-23 16:05:30 +00:00
Dev
68e73e4d86 Update arenafighterevent.json and arenafighter.json loot to have weights (copied from raiders) 2024-02-23 11:16:48 +00:00