Commit Graph

2005 Commits

Author SHA1 Message Date
Dev
60e82cf3f9 Updated Insured item data after a raid 2024-08-29 17:06:28 +01:00
Dev
6d9db36a78 Refreshed bot data values 2024-08-28 12:17:41 +01:00
crustyselenium
0342a0c39c 3.10.0-DEV WIP: Fixes #771 - Quest items not appearing on the case of dying after collecting them. Fixes an issue with gulp v5 corrupting pngs. (!403)
See #771 for discussion and bug report. Implementation deletes the specific task's completedCondition so as to allow the item to appear again.

Gulp v5 has a known issue that corrupts pngs when copying or moving them, this turns off encoding for the copying assets part of the build task.
Reference was [this stack post](https://stackoverflow.com/questions/78391263/copying-images-with-gulp-are-corrupted-damaged).

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/403
Co-authored-by: crustyselenium <crustyselenium@gmail.com>
Co-committed-by: crustyselenium <crustyselenium@gmail.com>
2024-08-27 22:15:08 +00:00
Dev
32066d0e3b Updated interface to match dumps 2024-08-26 21:32:20 +01:00
Kaeno
ae6f2e4417 Gear stand changes to match dump data. Will cause client to hang. 2024-08-26 21:31:31 +01:00
CWX
05c4bb1946 Update comments, refactor check 2024-08-26 20:47:09 +01:00
CWX
b3b36c37ee dont send upgrades back to client for gear area 2024-08-26 20:39:04 +01:00
Dev
7dd240b600 Updated returnPlayerOffer() to regenerate root items' parentId 2024-08-26 20:31:36 +01:00
Dev
0d611eae24 Add pocket item to mannequin on area upgrade 2024-08-26 18:54:10 +01:00
Dev
7dfa911213 Added comments to function 2024-08-26 14:23:23 +01:00
Dev
4f8b926ad5 Removed isFunctional limit on reward item filter 2024-08-26 13:55:42 +01:00
Dev
98b19ff1db Added cultistCircle config section to HideoutConfig and made use of values 2024-08-26 13:41:59 +01:00
Dev
63cf9ae132 Created new CircleOfCultist service and transplanted all code from Hideout controller into it 2024-08-26 11:46:38 +01:00
Dev
6803ee6241 Cultist circle:
Added support for weapon/armor rewards
Added support for variable stack sizes (only ammo for now)
Added support for breaking out of reward item while loop if no item is found (5 attempts max)
Added helper function `itemHelper.getRandomisedAmmoStackSize()`
2024-08-26 11:17:10 +01:00
Dev
d720f7fa3a Refactor of Circle of sacrifice code, added getRewardsWithinBudget() 2024-08-25 19:29:13 +01:00
Dev
768a275253 Logged error when nothing can be placed in reward grid 2024-08-25 15:13:50 +01:00
Dev
d3e7e1006b Increased multipler to 140%
Limited reward items to 5
2024-08-25 15:02:18 +01:00
Dev
94f3bd0d02 Removed debug/redundant code 2024-08-25 14:47:02 +01:00
Dev
c13d5c49a5 Added functionality to send player rewards based on cost of items sacrificed 2024-08-25 14:32:29 +01:00
TetrisGG
eee46aad30 Fix CircleOfCultists not finishing (!402)
Production resp should be null according to network dumps. Also instead of delete nulled out the recipe, so that it properly overwrites the id.

Co-authored-by: TetrisGG <tetrisggdev@gmail.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/402
Co-authored-by: TetrisGG <tetrisgg@noreply.dev.sp-tarkov.com>
Co-committed-by: TetrisGG <tetrisgg@noreply.dev.sp-tarkov.com>
2024-08-25 13:30:10 +00:00
Dev
244fe62617 Added code to create a pool of items the player needs to complete crafts/upgrade areas in their hideout for the cultist circle rewards 2024-08-25 13:46:47 +01:00
W1ngZ
eff5f14e5c Added feature to keep daily quest type when replacing. Refering issue #745 (!400)
## Added:
* Config to keep daily quest type

## Changed:
* changeRepeatableQuest to check if the daily quest type should be kept the same

Co-authored-by: W1ngZ <W1ngZ@NoRealMail.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/400
Co-authored-by: W1ngZ <w1ngz@noreply.dev.sp-tarkov.com>
Co-committed-by: W1ngZ <w1ngz@noreply.dev.sp-tarkov.com>
2024-08-25 07:56:48 +00:00
Dev
c8e66de039 Refactored addUpdateInventoryItemToProfile()and added addMissingPresetStandItemsToProfile() 2024-08-24 22:34:53 +01:00
Dev
3ac4074434 Added handling of twitch 2024 gamble boxes
Improved random loot box system to support `rewardTypePool` instead of `rewardTplPool`
2024-08-24 20:32:18 +01:00
Kaeno
150ae6637e Merge branch '3.10.0-DEV' of https://dev.sp-tarkov.com/SPT/Server into 3.10.0-DEV 2024-08-23 23:51:03 +01:00
Kaeno
655c0d9f27 Add check to only replace items if equipment id matches. Preventing from profile breaking 2024-08-23 23:50:52 +01:00
Dev
557dc55a33 Implemented inclusion of standx items when updating/installing hideout equipment area
Set area to level 0 for USEC
Removed unnecessary mannequin pose array from dev profiles
2024-08-23 23:41:50 +01:00
Kaeno
171fdfd6dd Remove FiR status from items on run through. Added toggle to always keep FiR status on items regardless of end raid status 2024-08-23 19:20:44 +01:00
TetrisGG
386b93e7e6 Handle Softinsertslots when insuring armor (!401)
fixes SPT/Issues#765
Tested with Uptodate Bleedingedge

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/401
Co-authored-by: TetrisGG <dmiller2606@gmail.com>
Co-committed-by: TetrisGG <dmiller2606@gmail.com>
2024-08-23 16:35:17 +00:00
Dev
8d9a396914 Added back missing singleplayer/settings/raid/menu endpoint 2024-08-23 17:08:14 +01:00
Dev
8fc2428239 Added helper function handleInsuredItemLostEvent() 2024-08-23 10:35:41 +01:00
Dev
3d1aa5e4fc Removed unused singleplayer/settings/raid/endstate endpoint 2024-08-23 10:19:23 +01:00
Dev
24cd94abd3 Expanded pmcConfig.maxBackpackLootTotalRub to work per PMC level
non-PMC backpack loot is no longer limited to 150,000 roubles
2024-08-22 20:42:47 +01:00
Dev
607189926a Removed chanceSameSideIsHostilePercent config property and code that uses it, now implemented inside every maps base.json 2024-08-22 19:08:40 +01:00
Dev
6d7c4d95b6 Added further progress on cultist circle - now rewards items upon completion
Now handles `HideoutDeleteProductionCommand` event, Deletes sacrificed items on craft start
Set craft time to 30 secs for debugging
2024-08-22 17:48:39 +01:00
Dev
eccf4ee969 Further improvements to cultist circle 2024-08-22 16:32:27 +01:00
Dev
38d2f88e0c Fixed circle craft not registering correctly 2024-08-22 12:43:30 +01:00
Dev
c6877f998b Updated StartTimestamp to be stored as a string 2024-08-22 12:34:54 +01:00
Dev
472c258187 Fix cultist circle craft not progressing due to lack of recipe 2024-08-22 11:05:32 +01:00
Dev
47fcff1338 Added further work to circle of sacrifice area 2024-08-22 10:32:35 +01:00
Dev
f24318603f Fixed flea market not showing items 2024-08-21 21:34:50 +01:00
Dev
3d8d09cc18 Expanded implementation of circleOfCultistProductionStart 2024-08-21 19:56:29 +01:00
Dev
409d146fa9 Added new properties to profile templates + updated some interfaces to match live 2024-08-21 17:50:12 +01:00
Dev
7316e6377d Added equipment preset area to addUpdateinventoryItemToProfile blacklist 2024-08-21 17:05:38 +01:00
Dev
1aa8233b4c Updated itemtpl enum 2024-08-21 15:34:55 +01:00
Dev
471c606e12 Updated production recipe interface to match live 2024-08-21 14:43:19 +01:00
Dev
f4d1ac9097 Added TODO inside circleOfCultistProductionStart 2024-08-21 13:45:03 +01:00
Dev
0a7394c2e3 Added timestamp to IHideoutCircleOfCultistProductionStartRequestData 2024-08-21 13:39:14 +01:00
Dev
726e4f4b2c Stubbed out HIDEOUT_CIRCLE_OF_CULTIST_PRODUCTION_START event 2024-08-21 13:36:51 +01:00
Dev
858026b5b9 Handled edge case handling for adding an item to a hideout area 2024-08-21 13:28:30 +01:00
Kaeno
87ac190b37 Update Wildspawntypenumber to add new boss 2024-08-21 13:26:55 +01:00
Kaeno
d4cc41d3fc Fix Dev profiles not having access to Weapon wall and Cultist stash 2024-08-21 13:26:10 +01:00
Dev
0839f34b9b Updated addContainerImprovementToProfile to better handle cultist circle 2024-08-21 13:05:59 +01:00
Dev
391273e7fb Fixed incorrect value assignment 2024-08-21 12:32:32 +01:00
Dev
c6e6b52baa Updated some map base jsons 2024-08-20 22:46:38 +01:00
Dev
23875045c9 Updated factory base json + interfaces 2024-08-20 22:20:16 +01:00
Dev
c45f4c5f4b Added s to Improvement
Updated hideout area enum
2024-08-20 21:19:00 +01:00
Dev
8e4c4e4a0f Updated various JSON files + interfaces 2024-08-20 20:58:46 +01:00
Dev
10dfb89787 Fixed incorrect IRestrictionsInRaid interface 2024-08-19 18:35:06 +01:00
DrakiaXYZ
bd5d4bfb66 Fix fuel ticks returning fuel to the player instead of removing it (!397)
Resolves the issue of incorrect fuel usage by using relative percentages for both the profile bonus and hideout management bonus
Add a sanity check to make sure we never return fuel to the player (No negative fuel consumption)
2024-08-19 16:58:45 +01:00
Alex McAuliffe
79f0949610 Updated bot tests 2024-08-19 16:55:11 +01:00
Alex McAuliffe
9e9baf49b3 Add types for variables on global scope. (!398)
Adds a type definition for the variables added to the global scope.

Personally i'd probably stick them in an object off the route and drop the G_prefix but didn't want to make any major changes with no reason.

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/398
Co-authored-by: Alex McAuliffe <alex@romanx.co.uk>
Co-committed-by: Alex McAuliffe <alex@romanx.co.uk>
(cherry picked from commit 18d39224a9)
2024-08-19 16:54:06 +01:00
Dev
5ffedfa91a Attempted to fix issue with calculateItemWorth() failing on child items without a upd object
Clone children when returned to prevent modification + add missing upd object to child before calculating price
2024-08-18 09:52:13 +01:00
Dev
52d9fbaeb6 Improved weapon mod selection when a default mod is desired but is incompatible with weapon
Introduced a `Set` into request object that holds conflicting items instead of constantly recalculating them when needed
2024-08-16 23:19:07 +01:00
Dev
2e8e91385e Fixed bad variable use
(cherry picked from commit daf70ea67f)
2024-08-15 20:17:18 +01:00
Dev
37fb49bffa Fixed issue that would cause repeatable completion quests to get stuck in an infinite loop
Improved performance of completion quests picking items to return

(cherry picked from commit f04382c9bb)
2024-08-15 20:17:10 +01:00
Dev
093afe002c #747 Fixed items added to ragfair configs custom blacklist still be sellable on flea by player
Moved confusing `isValidItem()` check out of `isItemOnCustomFleaBlacklist()` and into main function
Removed redundant blacklist check from flea item generation as its already covered in `isValidItem()`

(cherry picked from commit f46694a169)
2024-08-15 20:16:35 +01:00
Archangel
a4a3c8c89a Skip items that are listed in the custom blacklist from being set as sellable (!396)
Fixes issue #747

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/396
Co-authored-by: Archangel <jesse@archangel.wtf>
Co-committed-by: Archangel <jesse@archangel.wtf>
(cherry picked from commit 5017b01938)
2024-08-15 20:16:09 +01:00
Dev
4582bb6fe2 Improved handling of bot stock generation.
Moved code into own function
Expanded force stock check to look for any child items instead of ones for slot `mod_stock`
Expanded check to include additional slot names
2024-08-12 17:43:42 +01:00
Dev
ef950058bd Fixed calculateItemWorth() not handling child items lacking a upd object
(cherry picked from commit ebe1bc021f)
2024-08-11 18:34:28 +01:00
Dev
77c98a4cd4 Fixed invalid check inside getBonusValueFromProfile() 2024-08-09 22:05:07 +01:00
Dev
8014bdd06f Updated water filtering system to correctly check the craft progress against the ProductionTime value stored in the profile instead of the base ProductionTime value in the hideout json.
This is because the base value doesn't take into account any craft bonuses the profile has

After collecting a product from a continious craft, `ProductionTime` in the profiles craft data will be refreshed, this resolves issues with adjusting the `production.json` craft times not applying to continuous crafts
2024-08-09 16:04:43 +01:00
TetrisGG
7b835f1501 Fix Bonuses in various Services using Find and not filter. 2024-08-09 15:03:50 +01:00
Dev
2a52af1275 Improved logic of getBonusValueFromProfile() 2024-08-08 22:36:32 +01:00
Dev
1066a138ac Added function getBonusValueFromProfile to profileHelper
(cherry picked from commit d97e717f76)
2024-08-08 18:31:04 +01:00
Cj
967dc15564 ProfileFixerService Refactor (!391)
Refactor to remove legacy code that bloats the `ProfileFixerService` class. Most of which is old profile porting code, some being old profile fixes. Organizes code in the class so that public members are at the top (as they should be). Finally break out some code into their own methods so they're not in the primary method for the class `checkForAndFixPmcProfileIssues`.

I have tested this with a developer profile, an EOD profile and a Standard profile. I've encountered no issues in my own testing.

Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/391
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
2024-08-08 17:09:52 +00:00
Dev
2fbcee22bd Fixed container errors due to biome 2024-08-07 22:09:46 +01:00
Dev
fc8769ba30 Basic implementation of pocket tpl quest reward handling 2024-08-03 23:10:54 +01:00
Dev
18158bb4dc Fixed FiR status persisting after death for items inside secure container 2024-08-02 15:54:39 +01:00
witek
59308604fa Fix logs paths (!390)
When compiled natively to linux, logfiles are saved in main SPT folder instead of default location. It's caused by file paths being hardcoded as text.
This patch fixes logs location on linux build.

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/390
Co-authored-by: witek <falls-toluene.0q@icloud.com>
Co-committed-by: witek <falls-toluene.0q@icloud.com>
(cherry picked from commit 3edf0f2ff9)
2024-07-31 20:14:20 +01:00
MadByte
a52c81e270 Changed mod path for loading bundles from the server to be relative (!389)
**Before merging: Please test on a real Windows installation if possible!**

I tested this on Linux as well as inside a Windows VM hosted on Linux, but wasn't able to test it on a real Windows installation.

This commit fixes an issue with loading bundles from a native Linux server:

When compiling the server natively for Linux & installing some mods, everything works except for mods trying to load bundles from the server. Reason is a malformed path to the bundle:

```ts
2024-07-30 23:48:16.968 +02:00|0.14.9.1.30626|Error|Default|
EXCEPTION: System.IO.DirectoryNotFoundException: Could not find a part of the path "C:\home\USER\Games\escape-from-tarkov\drive_c\SPTarkov\user\mods\Bloody-Bullet-Wounds\bundles\assets\systems\effects\particlesystems\effects.bundle".
```

`process.cwd()` returns the linux-agnostic path of course, but for some reason it also returns `C:`.
Changing the line to `modpath.slice(0, -1).replace(/\\/g, "/");` seems to work and the bundles seem to get loaded without issues (did a quick test raid), even without passing the absolute path to the  mod.

I tried to check why that is, and I think node is able to [get the cwd and resolve the relative path](4d1d88118b/src/path.cc (L101)) by itself..

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/389
Co-authored-by: MadByte <madbyte@noreply.dev.sp-tarkov.com>
Co-committed-by: MadByte <madbyte@noreply.dev.sp-tarkov.com>
(cherry picked from commit 6f010acfca)
2024-07-31 20:14:12 +01:00
Dev
8f67f75930 Improved how generateMultipleBotsAndCache() and returnSingleBotFromCache() handles missing raid settings from AppContext 2024-07-30 12:09:28 +01:00
DrakiaXYZ
e295cda571 Fix issue in BotLevelGenerator when high level (!388)
Previously `highestValue` could be lower than `lowestValue`, resulting in an exception. These values are now generated in the same method and clamped

Add a catch to the botgen promise await so we get more useful errors if botgen fails

Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/388
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
(cherry picked from commit ee1eb7d690)
2024-07-30 08:29:04 +01:00
RomanxTheLast
f12c650774 Add async to the handleRequest chain in HttpServer (!387)
The httpListeners are promise based but they aren't awaited when handling the request.

I found this while implementing another version of HttpServer in a mod but couldn't actually find where this would cause an issue so feel free to close this if you think it's not worth it.

Reviewed-on: https://dev.sp-tarkov.com/SPT/Server/pulls/387
Co-authored-by: RomanxTheLast <alex@romanx.co.uk>
Co-committed-by: RomanxTheLast <alex@romanx.co.uk>
(cherry picked from commit 398bf43444)
2024-07-28 14:45:25 +01:00
Dev
c114d4285f Removed redundant function 2024-07-28 13:19:52 +01:00
Dev
852157aabf Fixed an issue where revolvers/rpd/ppsh would not properly filter out cartridges during ammo selection 2024-07-28 13:19:34 +01:00
Dev
2f412641b2 Further improvements to weapon mod generation 2024-07-28 11:42:45 +01:00
Dev
af33625a5c Improved pickWeaponModTplForSlotFromPool(), now pre-sorts mod pool prior to adding it to exhaustableModPool and processing 2024-07-28 00:12:04 +01:00
Dev
0c42a38306 Add null protection to playerHasRecievedMaxNumberOfGift() 2024-07-25 23:18:28 +01:00
Dev
0cb179f8e1 Make use of SideType.SAVAGE enum 2024-07-25 19:12:26 +01:00
Dev
4a1a5d924c Added item reward pools for Unlocked supply create (x)
Added item reward pools for `Unlocked equipment create (x)`
Added support for weapon/armor presets inside `getRandomLootContainerLoot()`
Expanded pool for `Unlocked valuables crate (x)",` by 8 items
2024-07-25 12:17:40 +01:00
Dev
797d75fd4f Added a weighting bias to the level chosen for bots, favors the higher value 2024-07-25 10:34:54 +01:00
Dev
adcd0194bf Improved bot generation comments
(cherry picked from commit e7f56edf0c)
2024-07-25 09:38:59 +01:00
Dev
de53abf002 Rounded flea offers requirementsCost to nearest int 2024-07-24 09:26:08 +01:00
Dev
7be6b47e23 Fixed various Biome issues 2024-07-23 17:30:20 +01:00
Refringe
5740774a46
Apply Biome Formatting
This is the result of running `npm run format` which applies the Biome formatting rules. Rejoice!
2024-07-23 11:12:53 -04:00
Refringe
7c76342ee2
Merge remote-tracking branch 'origin/310-dev' 2024-07-23 11:03:32 -04:00
Dev
951655e846 Removed redundant rating check now it has been moved to ProfileFixerService 2024-07-23 13:16:54 +01:00
Dev
3820b97531 Added null protected to playerLevelFulfillsQuestRequirement()
(cherry picked from commit c90b8670f2)
2024-07-23 09:07:26 +01:00
Dev
8c23a32755 Merge branch '310-dev'
# Conflicts:
#	project/.eslintrc.json
#	project/assets/configs/core.json
#	project/assets/configs/ragfair.json
#	project/assets/database/locations/bigmap/base.json
#	project/assets/database/locations/factory4_day/base.json
#	project/assets/database/locations/interchange/base.json
#	project/assets/database/locations/lighthouse/base.json
#	project/assets/database/locations/sandbox/base.json
#	project/assets/database/locations/sandbox_high/base.json
#	project/assets/database/locations/shoreline/base.json
#	project/assets/database/locations/tarkovstreets/base.json
#	project/assets/database/locations/woods/base.json
#	project/package.json
#	project/src/controllers/BotController.ts
#	project/src/controllers/GameController.ts
#	project/src/routers/static/InraidStaticRouter.ts
2024-07-22 23:14:47 +01:00