diff --git a/project/Server.code-workspace b/project/Server.code-workspace index 77c6e1c0..fd11a4d5 100644 --- a/project/Server.code-workspace +++ b/project/Server.code-workspace @@ -11,6 +11,9 @@ "editor.codeActionsOnSave": { "source.organizeImports.biome": "explicit", "quickfix.biome": "explicit" + }, + "[jsonc]": { + "editor.defaultFormatter": "biomejs.biome" } }, "extensions": { @@ -31,16 +34,10 @@ "runtimeVersion": "22.12.0", "runtimeExecutable": "tsx", "request": "launch", - "runtimeArgs": [ - "watch", - "--clear-screen=false" - ], + "runtimeArgs": ["watch", "--clear-screen=false"], "console": "integratedTerminal", "internalConsoleOptions": "neverOpen", - "skipFiles": [ - "/**", - "${workspaceFolder}/node_modules/**", - ], + "skipFiles": ["/**", "${workspaceFolder}/node_modules/**"] }, { "name": "Run Vitest Tests", @@ -48,16 +45,10 @@ "runtimeVersion": "22.12.0", "runtimeExecutable": "npm", "request": "launch", - "runtimeArgs": [ - "run", - "test" - ], + "runtimeArgs": ["run", "test"], "console": "integratedTerminal", "internalConsoleOptions": "neverOpen", - "skipFiles": [ - "/**", - "${workspaceFolder}/node_modules/**", - ], + "skipFiles": ["/**", "${workspaceFolder}/node_modules/**"] } ] } diff --git a/project/assets/configs/gifts.json b/project/assets/configs/gifts.json index 8f055300..6d460052 100644 --- a/project/assets/configs/gifts.json +++ b/project/assets/configs/gifts.json @@ -8522,209 +8522,239 @@ "associatedEvent": "Promo", "maxToSendPlayer": 5 }, - "NewYear2024": { - "items": [{ - "_id": "6773b39ccf4c2fe4e50a7ec3", - "_tpl": "67124dcfa3541f2a1f0e788b", - "upd": { - "FireMode": { - "FireMode": "single" - }, - "Repairable": { - "Durability": 100, - "MaxDurability": 100 - } - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec4", - "_tpl": "6719023b612cc94b9008e78c", - "parentId": "6773b39ccf4c2fe4e50a7ec3", - "slotId": "mod_stock" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec5", - "_tpl": "6709133fa532466d5403fb7c", - "parentId": "6773b39ccf4c2fe4e50a7ec3", - "slotId": "mod_magazine" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec6", - "_tpl": "670fd0a8d8d4eae4790c8187", - "parentId": "6773b39ccf4c2fe4e50a7ec3", - "slotId": "mod_barrel" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec7", - "_tpl": "6710cea62bb09af72f0e6bf8", - "parentId": "6773b39ccf4c2fe4e50a7ec6", - "slotId": "mod_mount" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec8", - "_tpl": "57d17c5e2459775a5c57d17d", - "parentId": "6773b39ccf4c2fe4e50a7ec7", - "slotId": "mod_tactical_003" - }, { - "_id": "6773b39ccf4c2fe4e50a7ec9", - "_tpl": "6165ac8c290d254f5e6b2f6c", - "parentId": "6773b39ccf4c2fe4e50a7ec3", - "slotId": "mod_scope" - }, { - "_id": "6773b39ccf4c2fe4e50a7ecb", - "_tpl": "6709133fa532466d5403fb7c", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ecd", - "_tpl": "6709133fa532466d5403fb7c", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ecf", - "_tpl": "6709133fa532466d5403fb7c", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed1", - "_tpl": "5c0d591486f7744c505b416f", - "upd": { - "StackObjectsCount": 20 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed3", - "_tpl": "5c0d591486f7744c505b416f", - "upd": { - "StackObjectsCount": 20 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed5", - "_tpl": "5c0d591486f7744c505b416f", - "upd": { - "StackObjectsCount": 20 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed6", - "_tpl": "5ab8e79e86f7742d8b372e78", - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed7", - "_tpl": "65732688d9d89ff7ac0d9c4c", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Soft_armor_front" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed8", - "_tpl": "657326978c1cc6dcd9098b56", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Soft_armor_back" - }, { - "_id": "6773b39ccf4c2fe4e50a7ed9", - "_tpl": "657326a28c1cc6dcd9098b5a", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Soft_armor_left" - }, { - "_id": "6773b39ccf4c2fe4e50a7eda", - "_tpl": "657326b08c1cc6dcd9098b5e", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "soft_armor_right" - }, { - "_id": "6773b39ccf4c2fe4e50a7edb", - "_tpl": "657326bc5d3a3129fb05f36b", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Collar" - }, { - "_id": "6773b39ccf4c2fe4e50a7edc", - "_tpl": "656f611f94b480b8a500c0db", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Front_plate" - }, { - "_id": "6773b39ccf4c2fe4e50a7edd", - "_tpl": "65573fa5655447403702a816", - "parentId": "6773b39ccf4c2fe4e50a7ed6", - "slotId": "Back_plate" - }, { - "_id": "6773b39ccf4c2fe4e50a7ede", - "_tpl": "675956062f6ddfe8ff0e2806", - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7edf", - "_tpl": "676307c004856a0b3c0dfffd", - "parentId": "6773b39ccf4c2fe4e50a7ede", - "slotId": "Helmet_top" - }, { - "_id": "6773b39ccf4c2fe4e50a7ee0", - "_tpl": "676307b4d9ec0af3d9001fa8", - "parentId": "6773b39ccf4c2fe4e50a7ede", - "slotId": "Helmet_back" - }, { - "_id": "6773b39ccf4c2fe4e50a7ee2", - "_tpl": "674589d98dd67746010329e6", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ee4", - "_tpl": "67458794e21e5d724e066976", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ee6", - "_tpl": "5d40407c86f774318526545a", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7ee8", - "_tpl": "5d40407c86f774318526545a", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7eea", - "_tpl": "5d403f9186f7743cac3f229b", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" - }, { - "_id": "6773b39ccf4c2fe4e50a7eec", - "_tpl": "5d403f9186f7743cac3f229b", - "upd": { - "StackObjectsCount": 1 - }, - "parentId": "6773b39ccf4c2fe4e50a7ec2", - "slotId": "main" + "NewYear2024": { + "items": [ + { + "_id": "6773b39ccf4c2fe4e50a7ec3", + "_tpl": "67124dcfa3541f2a1f0e788b", + "upd": { + "FireMode": { + "FireMode": "single" + }, + "Repairable": { + "Durability": 100, + "MaxDurability": 100 } - ], - "sender": "System", + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec4", + "_tpl": "6719023b612cc94b9008e78c", + "parentId": "6773b39ccf4c2fe4e50a7ec3", + "slotId": "mod_stock" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec5", + "_tpl": "6709133fa532466d5403fb7c", + "parentId": "6773b39ccf4c2fe4e50a7ec3", + "slotId": "mod_magazine" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec6", + "_tpl": "670fd0a8d8d4eae4790c8187", + "parentId": "6773b39ccf4c2fe4e50a7ec3", + "slotId": "mod_barrel" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec7", + "_tpl": "6710cea62bb09af72f0e6bf8", + "parentId": "6773b39ccf4c2fe4e50a7ec6", + "slotId": "mod_mount" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec8", + "_tpl": "57d17c5e2459775a5c57d17d", + "parentId": "6773b39ccf4c2fe4e50a7ec7", + "slotId": "mod_tactical_003" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ec9", + "_tpl": "6165ac8c290d254f5e6b2f6c", + "parentId": "6773b39ccf4c2fe4e50a7ec3", + "slotId": "mod_scope" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ecb", + "_tpl": "6709133fa532466d5403fb7c", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ecd", + "_tpl": "6709133fa532466d5403fb7c", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ecf", + "_tpl": "6709133fa532466d5403fb7c", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed1", + "_tpl": "5c0d591486f7744c505b416f", + "upd": { + "StackObjectsCount": 20 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed3", + "_tpl": "5c0d591486f7744c505b416f", + "upd": { + "StackObjectsCount": 20 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed5", + "_tpl": "5c0d591486f7744c505b416f", + "upd": { + "StackObjectsCount": 20 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed6", + "_tpl": "5ab8e79e86f7742d8b372e78", + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed7", + "_tpl": "65732688d9d89ff7ac0d9c4c", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Soft_armor_front" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed8", + "_tpl": "657326978c1cc6dcd9098b56", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Soft_armor_back" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ed9", + "_tpl": "657326a28c1cc6dcd9098b5a", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Soft_armor_left" + }, + { + "_id": "6773b39ccf4c2fe4e50a7eda", + "_tpl": "657326b08c1cc6dcd9098b5e", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "soft_armor_right" + }, + { + "_id": "6773b39ccf4c2fe4e50a7edb", + "_tpl": "657326bc5d3a3129fb05f36b", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Collar" + }, + { + "_id": "6773b39ccf4c2fe4e50a7edc", + "_tpl": "656f611f94b480b8a500c0db", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Front_plate" + }, + { + "_id": "6773b39ccf4c2fe4e50a7edd", + "_tpl": "65573fa5655447403702a816", + "parentId": "6773b39ccf4c2fe4e50a7ed6", + "slotId": "Back_plate" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ede", + "_tpl": "675956062f6ddfe8ff0e2806", + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7edf", + "_tpl": "676307c004856a0b3c0dfffd", + "parentId": "6773b39ccf4c2fe4e50a7ede", + "slotId": "Helmet_top" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ee0", + "_tpl": "676307b4d9ec0af3d9001fa8", + "parentId": "6773b39ccf4c2fe4e50a7ede", + "slotId": "Helmet_back" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ee2", + "_tpl": "674589d98dd67746010329e6", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ee4", + "_tpl": "67458794e21e5d724e066976", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ee6", + "_tpl": "5d40407c86f774318526545a", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7ee8", + "_tpl": "5d40407c86f774318526545a", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7eea", + "_tpl": "5d403f9186f7743cac3f229b", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + }, + { + "_id": "6773b39ccf4c2fe4e50a7eec", + "_tpl": "5d403f9186f7743cac3f229b", + "upd": { + "StackObjectsCount": 1 + }, + "parentId": "6773b39ccf4c2fe4e50a7ec2", + "slotId": "main" + } + ], + "sender": "System", "messageText": "New year present!", "collectionTimeHours": 72, "associatedEvent": "Promo", "maxToSendPlayer": 5 - } + } } } diff --git a/project/assets/configs/inventory.json b/project/assets/configs/inventory.json index f55bac67..96b67461 100644 --- a/project/assets/configs/inventory.json +++ b/project/assets/configs/inventory.json @@ -1411,7 +1411,7 @@ "_type": "opened case - walter event quest", "rewardCount": 4, "foundInRaid": true, - "rewardTplPool": {"67409848d0b2f8eb9b034db9": 1} + "rewardTplPool": { "67409848d0b2f8eb9b034db9": 1 } }, "674098588466ebb03408b210": { "_type": "opened box - walter event quest", @@ -1596,5 +1596,5 @@ "skillGainMultiplers": { "Strength": 1 }, - "deprioritisedMoneyContainers": ["590c60fc86f77412b13fddcf", "5d235bb686f77443f4331278"] + "deprioritisedMoneyContainers": ["590c60fc86f77412b13fddcf", "5d235bb686f77443f4331278"] } diff --git a/project/assets/configs/item.json b/project/assets/configs/item.json index 3b9ba10b..aa65ded2 100644 --- a/project/assets/configs/item.json +++ b/project/assets/configs/item.json @@ -52,12 +52,12 @@ "66da1b546916142b3b022777", "670ad7f1ad195290cd00da7a", "66ec2aa6daf127599c0c31f1", - "67654a6759116d347b0bfb86", - "5751916f24597720a27126df", - "57518f7724597720a31c09ab", - "57518fd424597720c85dbaaa", - "5a043f2c86f7741aa57b5145", - "5a0448bc86f774736f14efa8" + "67654a6759116d347b0bfb86", + "5751916f24597720a27126df", + "57518f7724597720a31c09ab", + "57518fd424597720c85dbaaa", + "5a043f2c86f7741aa57b5145", + "5a0448bc86f774736f14efa8" ], "rewardItemTypeBlacklist": ["65649eb40bf0ed77b8044453"], "lootableItemBlacklist": ["660bbc47c38b837877075e47", "660bc341c38b837877075e4c"], @@ -122,21 +122,21 @@ "671d8b38b769f0d88c0950f8", "671d8b8c0959c721a50ca838", "660bc341c38b837877075e4c", - "67409848d0b2f8eb9b034db9", - "67449b6c89d5e1ddc603f504", - "675aab0d6b6addc02a08f097", - "675aaae1dcf102478202c537", - "675aaa9a3107dac100063331", - "675aaae75a3ab8372d0b02a7", - "675aaab74bca0b001d02f356", - "675aaa8f7f3c962069072b27", - "675aaaf674a7619a5304c233", - "675aaa003107dac10006332f", - "6764207f2fa5e32733055c4a", - "6764202ae307804338014c1a", - "6707d13e4e617ec94f0e5631", - "675dc9d37ae1a8792107ca96", - "675dcb0545b1a2d108011b2b" + "67409848d0b2f8eb9b034db9", + "67449b6c89d5e1ddc603f504", + "675aab0d6b6addc02a08f097", + "675aaae1dcf102478202c537", + "675aaa9a3107dac100063331", + "675aaae75a3ab8372d0b02a7", + "675aaab74bca0b001d02f356", + "675aaa8f7f3c962069072b27", + "675aaaf674a7619a5304c233", + "675aaa003107dac10006332f", + "6764207f2fa5e32733055c4a", + "6764202ae307804338014c1a", + "6707d13e4e617ec94f0e5631", + "675dc9d37ae1a8792107ca96", + "675dcb0545b1a2d108011b2b" ], "bossItems": [ "6275303a9f372d6ea97f9ec7", @@ -183,204 +183,204 @@ "63a898a328e385334e0640a5": { "price": 20000, "parentId": "5b5f6fa186f77409407a7eb7" }, "63a897c6b1ff6e29734fcc95": { "price": 40000, "parentId": "5b5f6fa186f77409407a7eb7" } }, - "customItemGlobalPresets": [ - { - "_changeWeaponName": false, - "_encyclopedia": "675956062f6ddfe8ff0e2806", - "_id": "6777b37393a9a6f10ea57501", - "_items": [ - { - "_id": "6777bee3324b2e0cf7b7cfe1", - "_tpl": "675956062f6ddfe8ff0e2806" - }, - { - "_id": "6777c029e3703d1f9dc47d15", - "_tpl": "676307c004856a0b3c0dfffd", - "parentId": "6777bee3324b2e0cf7b7cfe1", - "slotId": "Helmet_top" - }, - { - "_id": "6777c030386bec3cd3c41b6e", - "_tpl": "676307b4d9ec0af3d9001fa8", - "parentId": "6777bee3324b2e0cf7b7cfe1", - "slotId": "Helmet_back" - } - ], - "_name": "MTEK FLUX Ballistic helmet (MultiCam Alpine) Default", - "_parent": "6777bee3324b2e0cf7b7cfe1", - "_type": "Preset" - }, - { - "_changeWeaponName": false, - "_encyclopedia": "6759655674aa5e0825040d62", - "_id": "6777bf37e10ffdb431ff9508", - "_items": [ - { - "_id": "6777bf03ad549e66e7ad06b2", - "_tpl": "6759655674aa5e0825040d62" - }, - { - "_id": "6777c02180ddaee0b54493da", - "_tpl": "676307c004856a0b3c0dfffd", - "parentId": "6777bf03ad549e66e7ad06b2", - "slotId": "Helmet_top" - }, - { - "_id": "6777c00f41b022243abdac99", - "_tpl": "676307b4d9ec0af3d9001fa8", - "parentId": "6777bf03ad549e66e7ad06b2", - "slotId": "Helmet_back" - } - ], - "_name": "MTEK FLUX Ballistic helmet (Olive Drab) Default", - "_parent": "6777bf03ad549e66e7ad06b2", - "_type": "Preset" - }, - { - "_changeWeaponName": false, - "_encyclopedia": "67597ceea35600b4c10cea86", - "_id": "6777bfee0658691ef27d9993", - "_items": [ - { - "_id": "6777bfaaaf1999ce0701bc00", - "_tpl": "67597ceea35600b4c10cea86" - }, - { - "_id": "6777c01b07b5d347d6b99404", - "_tpl": "676307ded8b241b4f703a3e8", - "parentId": "6777bfaaaf1999ce0701bc00", - "slotId": "Helmet_top" - }, - { - "_id": "6777c0033f374912b965ae5a", - "_tpl": "676307d3d9ec0af3d9001fac", - "parentId": "6777bfaaaf1999ce0701bc00", - "slotId": "Helmet_back" - } - ], - "_name": "MTEK FLUX Ballistic helmet (Coyote) Default", - "_parent": "6777bfaaaf1999ce0701bc00", - "_type": "Preset" - }, - { - "_changeWeaponName": false, - "_encyclopedia": "67597d241d5a44f2f605df06", - "_id": "6777c1244557b9b1474da362", - "_items": [ - { - "_id": "6777c10f4989fc544063b5a1", - "_tpl": "67597d241d5a44f2f605df06" - }, - { - "_id": "6777c1293c00b35cd6960536", - "_tpl": "676307ded8b241b4f703a3e8", - "parentId": "6777c10f4989fc544063b5a1", - "slotId": "Helmet_top" - }, - { - "_id": "6777c12f8fc234973af0cf16", - "_tpl": "676307d3d9ec0af3d9001fac", - "parentId": "6777c10f4989fc544063b5a1", - "slotId": "Helmet_back" - } - ], - "_name": "MTEK FLUX Ballistic helmet (Coyote/MultiCam Arid) Default", - "_parent": "6777c10f4989fc544063b5a1", - "_type": "Preset" - }, - { - "_changeWeaponName": false, - "_encyclopedia": "674d91ce6e862d5a95059ed6", - "_id": "67784df15058057382b28f87", - "_items": [ - { - "_id": "67784dfaf57296ecbdbfc87f", - "_tpl": "674d91ce6e862d5a95059ed6" - }, - { - "_id": "67784e27ee352de60dc982a3", - "_tpl": "6575ea3060703324250610da", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Soft_armor_front" - }, - { - "_id": "67784e32d75f52daffe36de5", - "_tpl": "6575ea4cf6a13a7b7100adc4", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Soft_armor_back" - }, - { - "_id": "67784e36e778f8aace662e1d", - "_tpl": "6575ea5cf6a13a7b7100adc8", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Soft_armor_left" - }, - { - "_id": "67784e3c0e4afac4ebdab52d", - "_tpl": "6575ea6760703324250610de", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "soft_armor_right" - }, - { - "_id": "67784e40832d547cb2c986bf", - "_tpl": "6575ea719c7cad336508e418", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Collar" - }, - { - "_id": "67784e446c92fcb0e0d8fea8", - "_tpl": "6575ea7c60703324250610e2", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Groin" - }, - { - "_id": "67784e473abf2a39a05dba5a", - "_tpl": "656f611f94b480b8a500c0db", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Front_plate" - }, - { - "_id": "67784e4b934ace8451681bee", - "_tpl": "656efaf54772930db4031ff5", - "parentId": "67784dfaf57296ecbdbfc87f", - "slotId": "Back_plate" - } - ], - "_name": "Body armor 6B13 M Killa Christmas Standard", - "_parent": "67784dfaf57296ecbdbfc87f", - "_type": "Preset" - }, - { - "_changeWeaponName": false, - "_encyclopedia": "6745895717824b1ec20570a6", - "_id": "677d14927f8ee8353d85918d", - "_items": [ - { - "_id": "677d14a27757dcc54a3054fb", - "_tpl": "6745895717824b1ec20570a6" - }, - { - "_id": "677d14abef2285ed18ee3e62", - "_tpl": "657baaf0b7e9ca9a02045c02", - "parentId": "677d14a27757dcc54a3054fb", - "slotId": "Helmet_top" - }, - { - "_id": "677d14b0024eda59d1544794", - "_tpl": "657bab6ec6f689d3a205b85f", - "parentId": "677d14a27757dcc54a3054fb", - "slotId": "Helmet_back" - }, - { - "_id": "677d14bb1dfea5b33fa31337", - "_tpl": "657babc6f58ba5a6250107a2", - "parentId": "677d14a27757dcc54a3054fb", - "slotId": "Helmet_ears" - } - ], - "_name": "6B47 Ratnik-BSh helmet (EMR Arctic cover) default", - "_parent": "677d14a27757dcc54a3054fb", - "_type": "Preset" - } - ] + "customItemGlobalPresets": [ + { + "_changeWeaponName": false, + "_encyclopedia": "675956062f6ddfe8ff0e2806", + "_id": "6777b37393a9a6f10ea57501", + "_items": [ + { + "_id": "6777bee3324b2e0cf7b7cfe1", + "_tpl": "675956062f6ddfe8ff0e2806" + }, + { + "_id": "6777c029e3703d1f9dc47d15", + "_tpl": "676307c004856a0b3c0dfffd", + "parentId": "6777bee3324b2e0cf7b7cfe1", + "slotId": "Helmet_top" + }, + { + "_id": "6777c030386bec3cd3c41b6e", + "_tpl": "676307b4d9ec0af3d9001fa8", + "parentId": "6777bee3324b2e0cf7b7cfe1", + "slotId": "Helmet_back" + } + ], + "_name": "MTEK FLUX Ballistic helmet (MultiCam Alpine) Default", + "_parent": "6777bee3324b2e0cf7b7cfe1", + "_type": "Preset" + }, + { + "_changeWeaponName": false, + "_encyclopedia": "6759655674aa5e0825040d62", + "_id": "6777bf37e10ffdb431ff9508", + "_items": [ + { + "_id": "6777bf03ad549e66e7ad06b2", + "_tpl": "6759655674aa5e0825040d62" + }, + { + "_id": "6777c02180ddaee0b54493da", + "_tpl": "676307c004856a0b3c0dfffd", + "parentId": "6777bf03ad549e66e7ad06b2", + "slotId": "Helmet_top" + }, + { + "_id": "6777c00f41b022243abdac99", + "_tpl": "676307b4d9ec0af3d9001fa8", + "parentId": "6777bf03ad549e66e7ad06b2", + "slotId": "Helmet_back" + } + ], + "_name": "MTEK FLUX Ballistic helmet (Olive Drab) Default", + "_parent": "6777bf03ad549e66e7ad06b2", + "_type": "Preset" + }, + { + "_changeWeaponName": false, + "_encyclopedia": "67597ceea35600b4c10cea86", + "_id": "6777bfee0658691ef27d9993", + "_items": [ + { + "_id": "6777bfaaaf1999ce0701bc00", + "_tpl": "67597ceea35600b4c10cea86" + }, + { + "_id": "6777c01b07b5d347d6b99404", + "_tpl": "676307ded8b241b4f703a3e8", + "parentId": "6777bfaaaf1999ce0701bc00", + "slotId": "Helmet_top" + }, + { + "_id": "6777c0033f374912b965ae5a", + "_tpl": "676307d3d9ec0af3d9001fac", + "parentId": "6777bfaaaf1999ce0701bc00", + "slotId": "Helmet_back" + } + ], + "_name": "MTEK FLUX Ballistic helmet (Coyote) Default", + "_parent": "6777bfaaaf1999ce0701bc00", + "_type": "Preset" + }, + { + "_changeWeaponName": false, + "_encyclopedia": "67597d241d5a44f2f605df06", + "_id": "6777c1244557b9b1474da362", + "_items": [ + { + "_id": "6777c10f4989fc544063b5a1", + "_tpl": "67597d241d5a44f2f605df06" + }, + { + "_id": "6777c1293c00b35cd6960536", + "_tpl": "676307ded8b241b4f703a3e8", + "parentId": "6777c10f4989fc544063b5a1", + "slotId": "Helmet_top" + }, + { + "_id": "6777c12f8fc234973af0cf16", + "_tpl": "676307d3d9ec0af3d9001fac", + "parentId": "6777c10f4989fc544063b5a1", + "slotId": "Helmet_back" + } + ], + "_name": "MTEK FLUX Ballistic helmet (Coyote/MultiCam Arid) Default", + "_parent": "6777c10f4989fc544063b5a1", + "_type": "Preset" + }, + { + "_changeWeaponName": false, + "_encyclopedia": "674d91ce6e862d5a95059ed6", + "_id": "67784df15058057382b28f87", + "_items": [ + { + "_id": "67784dfaf57296ecbdbfc87f", + "_tpl": "674d91ce6e862d5a95059ed6" + }, + { + "_id": "67784e27ee352de60dc982a3", + "_tpl": "6575ea3060703324250610da", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Soft_armor_front" + }, + { + "_id": "67784e32d75f52daffe36de5", + "_tpl": "6575ea4cf6a13a7b7100adc4", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Soft_armor_back" + }, + { + "_id": "67784e36e778f8aace662e1d", + "_tpl": "6575ea5cf6a13a7b7100adc8", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Soft_armor_left" + }, + { + "_id": "67784e3c0e4afac4ebdab52d", + "_tpl": "6575ea6760703324250610de", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "soft_armor_right" + }, + { + "_id": "67784e40832d547cb2c986bf", + "_tpl": "6575ea719c7cad336508e418", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Collar" + }, + { + "_id": "67784e446c92fcb0e0d8fea8", + "_tpl": "6575ea7c60703324250610e2", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Groin" + }, + { + "_id": "67784e473abf2a39a05dba5a", + "_tpl": "656f611f94b480b8a500c0db", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Front_plate" + }, + { + "_id": "67784e4b934ace8451681bee", + "_tpl": "656efaf54772930db4031ff5", + "parentId": "67784dfaf57296ecbdbfc87f", + "slotId": "Back_plate" + } + ], + "_name": "Body armor 6B13 M Killa Christmas Standard", + "_parent": "67784dfaf57296ecbdbfc87f", + "_type": "Preset" + }, + { + "_changeWeaponName": false, + "_encyclopedia": "6745895717824b1ec20570a6", + "_id": "677d14927f8ee8353d85918d", + "_items": [ + { + "_id": "677d14a27757dcc54a3054fb", + "_tpl": "6745895717824b1ec20570a6" + }, + { + "_id": "677d14abef2285ed18ee3e62", + "_tpl": "657baaf0b7e9ca9a02045c02", + "parentId": "677d14a27757dcc54a3054fb", + "slotId": "Helmet_top" + }, + { + "_id": "677d14b0024eda59d1544794", + "_tpl": "657bab6ec6f689d3a205b85f", + "parentId": "677d14a27757dcc54a3054fb", + "slotId": "Helmet_back" + }, + { + "_id": "677d14bb1dfea5b33fa31337", + "_tpl": "657babc6f58ba5a6250107a2", + "parentId": "677d14a27757dcc54a3054fb", + "slotId": "Helmet_ears" + } + ], + "_name": "6B47 Ratnik-BSh helmet (EMR Arctic cover) default", + "_parent": "677d14a27757dcc54a3054fb", + "_type": "Preset" + } + ] } diff --git a/project/assets/configs/pmc.json b/project/assets/configs/pmc.json index 65962a79..aee1e1c9 100644 --- a/project/assets/configs/pmc.json +++ b/project/assets/configs/pmc.json @@ -151,9 +151,9 @@ "675dc9d37ae1a8792107ca96", "675dcb0545b1a2d108011b2b", "6707d13e4e617ec94f0e5631", - "67408903268737ef6908d432", - "67499b9b909d2013670a5029", - "6638a5474e92f038531e210e" + "67408903268737ef6908d432", + "67499b9b909d2013670a5029", + "6638a5474e92f038531e210e" ], "useDifficultyOverride": false, "difficulty": "AsOnline", @@ -772,8 +772,8 @@ "hostilitySettings": { "pmcusec": { "additionalEnemyTypes": [ - "arenaFighterEvent", - "marksman", + "arenaFighterEvent", + "marksman", "peacemaker", "skier", "ravangeZryachiyEvent", @@ -796,14 +796,16 @@ "followerBigPipe", "followerBirdEye", "followerBully", - "followerBoarClose1", - "followerBoarClose2" + "followerBoarClose1", + "followerBoarClose2" ], "additionalFriendlyTypes": ["gifter", "shooterBTR", "sectactPriestEvent", "peacefullZryachiyEvent"], - "chancedEnemies": [{ + "chancedEnemies": [ + { "EnemyChance": 85, "Role": "pmcUSEC" - }, { + }, + { "EnemyChance": 100, "Role": "pmcBEAR" } @@ -815,8 +817,8 @@ }, "pmcbear": { "additionalEnemyTypes": [ - "arenaFighterEvent", - "marksman", + "arenaFighterEvent", + "marksman", "peacemaker", "skier", "ravangeZryachiyEvent", @@ -839,14 +841,16 @@ "followerBigPipe", "followerBirdEye", "followerBully", - "followerBoarClose1", - "followerBoarClose2" + "followerBoarClose1", + "followerBoarClose2" ], "additionalFriendlyTypes": ["gifter", "shooterBTR", "sectactPriestEvent", "peacefullZryachiyEvent"], - "chancedEnemies": [{ + "chancedEnemies": [ + { "EnemyChance": 85, "Role": "pmcBEAR" - }, { + }, + { "EnemyChance": 100, "Role": "pmcUSEC" } diff --git a/project/assets/configs/quest.json b/project/assets/configs/quest.json index 10062996..4e0af028 100644 --- a/project/assets/configs/quest.json +++ b/project/assets/configs/quest.json @@ -16,8 +16,8 @@ "5e381b0286f77420e3417a74", "5e4d4ac186f774264f758336", "639136d68ba6894d155e77cf", - "6613f3007f6666d56807c929", - "6613f307fca4f2f386029409" + "6613f3007f6666d56807c929", + "6613f307fca4f2f386029409" ], "profileBlacklist": { "unheard_edition": ["666314a50aa5c7436c00908a"] diff --git a/project/assets/configs/ragfair.json b/project/assets/configs/ragfair.json index e7450ca0..bb16a320 100644 --- a/project/assets/configs/ragfair.json +++ b/project/assets/configs/ragfair.json @@ -337,13 +337,13 @@ "newPriceHandbookMultiplier": 11 } }, - "itemPriceOverrideRouble":{ - "66bc98a01a47be227a5e956e": 500000, - "63a8970d7108f713591149f5": 50000, - "63a898a328e385334e0640a5": 100000, - "63a897c6b1ff6e29734fcc95": 200000, - "674d91ce6e862d5a95059ed6": 250000 - } + "itemPriceOverrideRouble": { + "66bc98a01a47be227a5e956e": 500000, + "63a8970d7108f713591149f5": 50000, + "63a898a328e385334e0640a5": 100000, + "63a897c6b1ff6e29734fcc95": 200000, + "674d91ce6e862d5a95059ed6": 250000 + } }, "tieredFlea": { "enabled": false, diff --git a/project/assets/configs/seasonalevents.json b/project/assets/configs/seasonalevents.json index 6981a20b..9644a60d 100644 --- a/project/assets/configs/seasonalevents.json +++ b/project/assets/configs/seasonalevents.json @@ -98,13 +98,13 @@ "5a43957686f7742a2c2f11b0": 150 } }, - "bosskilla": { + "bosskilla": { "ArmorVest": { "674d91ce6e862d5a95059ed6": 200 }, - "Headwear": { - "6759af0f9c8a538dd70bfae6": 200 - } + "Headwear": { + "6759af0f9c8a538dd70bfae6": 200 + } }, "bossknight": { "FaceCover": { @@ -242,7 +242,7 @@ "bear": { "FaceCover": { "5c1a1e3f2e221602b66cc4c2": 30, - "675ac888803644528007b3f6": 30 + "675ac888803644528007b3f6": 30 }, "Headwear": { "5a43957686f7742a2c2f11b0": 80, @@ -252,7 +252,7 @@ "usec": { "FaceCover": { "5c1a1e3f2e221602b66cc4c2": 30, - "675ac888803644528007b3f6": 30 + "675ac888803644528007b3f6": 30 }, "Headwear": { "5a43957686f7742a2c2f11b0": 80, @@ -261,28 +261,28 @@ } } }, - "eventLoot": { - "christmas": { - "assault": { - "Pockets": { - "5df8a6a186f77412640e2e80": 2200, - "5df8a72c86f77412640e2e83": 2200, - "5df8a77486f77412672a1e3f": 2200 - }, - "Backpack": { - "5df8a6a186f77412640e2e80": 2200, - "5df8a72c86f77412640e2e83": 2200, - "5df8a77486f77412672a1e3f": 2200, - "63a8970d7108f713591149f5": 250 - }, - "TacticalVest": { - "5df8a6a186f77412640e2e80": 2200, - "5df8a72c86f77412640e2e83": 2200, - "5df8a77486f77412672a1e3f": 2200 - } - } - } - }, + "eventLoot": { + "christmas": { + "assault": { + "Pockets": { + "5df8a6a186f77412640e2e80": 2200, + "5df8a72c86f77412640e2e83": 2200, + "5df8a77486f77412672a1e3f": 2200 + }, + "Backpack": { + "5df8a6a186f77412640e2e80": 2200, + "5df8a72c86f77412640e2e83": 2200, + "5df8a77486f77412672a1e3f": 2200, + "63a8970d7108f713591149f5": 250 + }, + "TacticalVest": { + "5df8a6a186f77412640e2e80": 2200, + "5df8a72c86f77412640e2e83": 2200, + "5df8a77486f77412672a1e3f": 2200 + } + } + } + }, "eventBotMapping": { "peacefullZryachiyEvent": "bossZryachiy", "sectactPriestEvent": "sectantPriest", @@ -8363,9 +8363,9 @@ "endDay": "31", "endMonth": "12", "settings": { - "enableChristmasHideout": true, + "enableChristmasHideout": true, "enableSanta": true, - "adjustBotAppearances": true + "adjustBotAppearances": true } }, { @@ -8376,13 +8376,13 @@ "startMonth": "1", "endDay": "1", "endMonth": "1", - "settings": { - "enableChristmasHideout": true, + "settings": { + "enableChristmasHideout": true, "enableSanta": true, - "adjustBotAppearances": true + "adjustBotAppearances": true } }, - { + { "enabled": true, "name": "christmas January", "type": "CHRISTMAS", @@ -8391,9 +8391,9 @@ "endDay": "7", "endMonth": "1", "settings": { - "enableChristmasHideout": true, + "enableChristmasHideout": true, "enableSanta": true, - "adjustBotAppearances": true + "adjustBotAppearances": true } }, { @@ -12314,11 +12314,11 @@ ] } }, - "christmasContainerIds": [ - "container_custom_DesignStuff_00427", - "container_Shopping_Mall_DesignStuff_00808", - "container_Lighthouse_DesignStuff_00001", - "container_shoreline_DesignStuff_00418", - "container_woods_design_stuff_00328" - ] + "christmasContainerIds": [ + "container_custom_DesignStuff_00427", + "container_Shopping_Mall_DesignStuff_00808", + "container_Lighthouse_DesignStuff_00001", + "container_shoreline_DesignStuff_00418", + "container_woods_design_stuff_00328" + ] } diff --git a/project/assets/configs/trader.json b/project/assets/configs/trader.json index 17a93ede..ea8b545e 100644 --- a/project/assets/configs/trader.json +++ b/project/assets/configs/trader.json @@ -365,7 +365,7 @@ "65ddcc9cfa85b9f17d0dfb07", "660312cc4d6cdfa6f500c703", "6655e35b6bc645cb7b059912", - "6759673c76e93d8eb20b2080" + "6759673c76e93d8eb20b2080" ], "coopExtractGift": { "sendGift": true, diff --git a/project/assets/configs/weather.json b/project/assets/configs/weather.json index 45c96594..5a77166a 100644 --- a/project/assets/configs/weather.json +++ b/project/assets/configs/weather.json @@ -97,56 +97,64 @@ "weights": [1, 2] } }, - "seasonDates": [{ + "seasonDates": [ + { "seasonType": 0, "name": "SUMMER", "startDay": "2", "startMonth": "6", "endDay": "15", "endMonth": "10" - }, { + }, + { "seasonType": 1, "name": "AUTUMN", "startDay": "15", "startMonth": "10", "endDay": "1", "endMonth": "11" - }, { + }, + { "seasonType": 4, "name": "AUTUMN_LATE", "startDay": "1", "startMonth": "11", "endDay": "21", "endMonth": "12" - }, { + }, + { "seasonType": 2, "name": "WINTER_START", "startDay": "21", "startMonth": "12", "endDay": "31", "endMonth": "12" - }, { + }, + { "seasonType": 2, "name": "WINTER_END", "startDay": "1", "startMonth": "1", "endDay": "9", "endMonth": "1" - }, { + }, + { "seasonType": 5, "name": "SPRING_EARLY", "startDay": "9", "startMonth": "1", "endDay": "25", "endMonth": "3" - }, { + }, + { "seasonType": 3, "name": "SPRING", "startDay": "25", "startMonth": "3", "endDay": "2", "endMonth": "6" - }, { + }, + { "seasonType": 4, "name": "STORM", "startDay": "24", diff --git a/project/biome.jsonc b/project/biome.jsonc index 5235e1fc..d3ab1259 100644 --- a/project/biome.jsonc +++ b/project/biome.jsonc @@ -8,24 +8,23 @@ ".editorconfig", ".git/*", ".pkg-cache/*", - ".vscode/*", + "assets/database/*", "build/*", "node_modules/*", "obj/*", - "out/*", - "src/services/ModCompilerService.ts", "tests/__cache__/*", "tests/__coverage__/*", "types/*", - "user/mods/*", - "user/profiles/*", - "assets/database/*" + "user/*" ] }, "linter": { "enabled": true, "rules": { "recommended": true, + "suspicious": { + "noExplicitAny": "warn" + }, "style": { "useImportType": "off" } @@ -34,17 +33,6 @@ "formatter": { "enabled": true, "formatWithErrors": false, - "ignore": [ - "**/.git", - "**/.pkg-cache", - "**/.vscode", - "**/build", - "**/node_modules", - "**/types", - "**/tests/__cache__", - "**/tests/__coverage__", - "**/.editorconfig" - ], "attributePosition": "auto", "indentStyle": "space", "indentWidth": 4, @@ -72,14 +60,7 @@ }, "overrides": [ { - "include": ["tests/*"], - "linter": { - "rules": { - "suspicious": { - "noExplicitAny": "off" - } - } - } + "include": ["tests/*"] } ] } diff --git a/project/package.json b/project/package.json index 9698c298..381bd8da 100644 --- a/project/package.json +++ b/project/package.json @@ -33,7 +33,7 @@ "gen:docs": "typedoc --options ./typedoc.json --entryPointStrategy expand ./src", "gen:items": "tsx ./src/tools/ItemTplGenerator/ItemTplGeneratorProgram.ts", "gen:productionquests": "tsx ./src/tools/ProductionQuestsGen/ProductionQuestsGenProgram.ts", - "gen:customisationstorage": "tsx ./src/tools/HideoutCustomisation/HideoutCustomisationProgram.ts" + "gen:customisationstorage": "tsx ./src/tools/HideoutCustomisation/HideoutCustomisationProgram.ts" }, "dependencies": { "atomically": "~1.7", diff --git a/project/src/controllers/RagfairController.ts b/project/src/controllers/RagfairController.ts index 5b42aca0..a0d390b5 100644 --- a/project/src/controllers/RagfairController.ts +++ b/project/src/controllers/RagfairController.ts @@ -335,7 +335,7 @@ export class RagfairController { // Figure out how many items the requirementsCost is applying to, and what the per-item price is const offerItemCount = Math.max( - offer.sellInOnePiece ? (offer.items[0].upd?.StackObjectsCount ?? 1) : 1, + offer.sellInOnePiece ? offer.items[0].upd?.StackObjectsCount ?? 1 : 1, ); const perItemPrice = offer.requirementsCost / offerItemCount; diff --git a/project/src/models/enums/ItemTpl.ts b/project/src/models/enums/ItemTpl.ts index 9f99cce5..d329361d 100644 --- a/project/src/models/enums/ItemTpl.ts +++ b/project/src/models/enums/ItemTpl.ts @@ -1,6 +1,5 @@ // This is an auto generated file, do not modify. Re-generate with `npm run gen:items` -export enum ItemTpl -{ +export enum ItemTpl { AMMOBOX_127X33_COPPER_20RND = "676009ddb623f3b8ba079419", AMMOBOX_127X33_FMJ_20RND = "676009ed8f1fee08740f9479", AMMOBOX_127X33_JHP_20RND = "676009fe8f1fee08740f947c", diff --git a/project/src/models/enums/Weapons.ts b/project/src/models/enums/Weapons.ts index b9dbaa5f..b4e57187 100644 --- a/project/src/models/enums/Weapons.ts +++ b/project/src/models/enums/Weapons.ts @@ -1,6 +1,5 @@ // This is an auto generated file, do not modify. Re-generate with `npm run gen:items` -export enum Weapons -{ +export enum Weapons { ASSAULTCARBINE_762X39_OP_SKS = "587e02ff24597743df3deaeb", ASSAULTCARBINE_762X39_SKS = "574d967124597745970e7c94", ASSAULTCARBINE_762X51_VPO_101_VEPR_HUNTER = "5c501a4d2e221602b412b540", diff --git a/project/src/models/spt/config/ISeasonalEventConfig.ts b/project/src/models/spt/config/ISeasonalEventConfig.ts index 5d2b75b0..c4d98eea 100644 --- a/project/src/models/spt/config/ISeasonalEventConfig.ts +++ b/project/src/models/spt/config/ISeasonalEventConfig.ts @@ -38,7 +38,7 @@ export interface ISeasonalEventSettings { enableSummoning: boolean; enableHalloweenHideout: boolean; enableChristmasHideout: boolean; - enableSanta: boolean, + enableSanta: boolean; adjustBotAppearances: boolean; addEventGearToBots: boolean; addEventLootToBots: boolean; diff --git a/project/src/servers/ws/SPTWebsocket.ts b/project/src/servers/ws/SPTWebsocket.ts index 4dedb252..e198240a 100644 --- a/project/src/servers/ws/SPTWebsocket.ts +++ b/project/src/servers/ws/SPTWebsocket.ts @@ -16,9 +16,9 @@ export class SPTWebSocket extends WebSocket { public closeAsync(): Promise { return new Promise((resolve, reject) => { - this.on('close', () => resolve()); - this.on('error', (err) => reject(err)); - this.close(); + this.on("close", () => resolve()); + this.on("error", (err) => reject(err)); + this.close(); }); - } -} \ No newline at end of file + } +} diff --git a/project/src/servers/ws/SptWebSocketConnectionHandler.ts b/project/src/servers/ws/SptWebSocketConnectionHandler.ts index ebbe9bec..f6bd1c09 100644 --- a/project/src/servers/ws/SptWebSocketConnectionHandler.ts +++ b/project/src/servers/ws/SptWebSocketConnectionHandler.ts @@ -55,7 +55,7 @@ export class SptWebSocketConnectionHandler implements IWebSocketConnectionHandle if (this.websocketPingHandler) { clearInterval(this.websocketPingHandler); } - + ws.on("message", async (msg) => { for (const wsmh of this.sptWebSocketMessageHandlers) { await wsmh.onSptMessage(sessionID, this.webSockets.get(sessionID), msg); diff --git a/project/src/services/ModCompilerService.ts b/project/src/services/ModCompilerService.ts index 3ea2747a..454225c6 100644 --- a/project/src/services/ModCompilerService.ts +++ b/project/src/services/ModCompilerService.ts @@ -1,23 +1,21 @@ import fs from "node:fs"; import path from "node:path"; -import { inject, injectable } from "tsyringe"; -import { ScriptTarget, ModuleKind, ModuleResolutionKind, transpileModule, CompilerOptions } from "typescript"; import { ProgramStatics } from "@spt/ProgramStatics"; import type { ILogger } from "@spt/models/spt/utils/ILogger"; import { ModHashCacheService } from "@spt/services/cache/ModHashCacheService"; import { VFS } from "@spt/utils/VFS"; +import { inject, injectable } from "tsyringe"; +import { CompilerOptions, ModuleKind, ModuleResolutionKind, ScriptTarget, transpileModule } from "typescript"; @injectable() -export class ModCompilerService -{ +export class ModCompilerService { protected serverDependencies: string[]; constructor( @inject("PrimaryLogger") protected logger: ILogger, @inject("ModHashCacheService") protected modHashCacheService: ModHashCacheService, @inject("VFS") protected vfs: VFS, - ) - { + ) { const packageJsonPath: string = path.join(__dirname, "../../package.json"); this.serverDependencies = Object.keys(JSON.parse(this.vfs.readFile(packageJsonPath)).dependencies); } @@ -29,33 +27,28 @@ export class ModCompilerService * @param modTypeScriptFiles * @returns */ - public async compileMod(modName: string, modPath: string, modTypeScriptFiles: string[]): Promise - { + public async compileMod(modName: string, modPath: string, modTypeScriptFiles: string[]): Promise { // Concatenate TS files into one string let tsFileContents = ""; let fileExists = true; // does every js file exist (been compiled before) - for (const file of modTypeScriptFiles) - { + for (const file of modTypeScriptFiles) { const fileContent = this.vfs.readFile(file); tsFileContents += fileContent; // Does equivalent .js file exist - if (!this.vfs.exists(file.replace(".ts", ".js"))) - { + if (!this.vfs.exists(file.replace(".ts", ".js"))) { fileExists = false; } } const hashMatches = this.modHashCacheService.calculateAndCompareHash(modName, tsFileContents); - if (fileExists && hashMatches) - { + if (fileExists && hashMatches) { // Everything exists and matches, escape early return; } - if (!hashMatches) - { + if (!hashMatches) { // Store / update hash in json file this.modHashCacheService.calculateAndStoreHash(modName, tsFileContents); } @@ -82,13 +75,11 @@ export class ModCompilerService * @param fileNames Paths to TS files * @param options Compiler options */ - protected async compile(fileNames: string[], options: CompilerOptions): Promise - { + protected async compile(fileNames: string[], options: CompilerOptions): Promise { // C:/snapshot/project || /snapshot/project const baseDir: string = __dirname.replace(/\\/g, "/").split("/").slice(0, 3).join("/"); - for (const filePath of fileNames) - { + for (const filePath of fileNames) { const destPath = filePath.replace(".ts", ".js"); const parsedPath = path.parse(filePath); const parsedDestPath = path.parse(destPath); @@ -97,20 +88,17 @@ export class ModCompilerService if (ProgramStatics.COMPILED) { replacedText = text.replace(/(@spt)/g, `${baseDir}/obj`); - for (const dependency of this.serverDependencies) - { + for (const dependency of this.serverDependencies) { replacedText = replacedText.replace(`"${dependency}"`, `"${baseDir}/node_modules/${dependency}"`); } - } - else - { + } else { replacedText = text.replace(/(@spt)/g, path.join(__dirname, "..").replace(/\\/g, "/")); } const output = transpileModule(replacedText, { compilerOptions: options }); - if (output.sourceMapText) - { + if (output.sourceMapText) { + // biome-ignore format: these mappings should not be formatted output.outputText = output.outputText.replace( "//# sourceMappingURL\=module.js.map", `//# sourceMappingURL\=${parsedDestPath.base}.map`, @@ -125,8 +113,7 @@ export class ModCompilerService fs.writeFileSync(destPath, output.outputText); } - while (!this.areFilesReady(fileNames)) - { + while (!this.areFilesReady(fileNames)) { await this.delay(200); } } @@ -136,8 +123,7 @@ export class ModCompilerService * @param fileNames * @returns */ - protected areFilesReady(fileNames: string[]): boolean - { + protected areFilesReady(fileNames: string[]): boolean { return fileNames.filter((x) => !this.vfs.exists(x.replace(".ts", ".js"))).length === 0; } @@ -146,8 +132,7 @@ export class ModCompilerService * @param ms Milliseconds * @returns */ - protected delay(ms: number): Promise - { + protected delay(ms: number): Promise { return new Promise((resolve) => setTimeout(resolve, ms)); } } diff --git a/project/src/services/SeasonalEventService.ts b/project/src/services/SeasonalEventService.ts index 5d193fd9..1fae2eca 100644 --- a/project/src/services/SeasonalEventService.ts +++ b/project/src/services/SeasonalEventService.ts @@ -11,7 +11,12 @@ import { SeasonalEventType } from "@spt/models/enums/SeasonalEventType"; import { IHttpConfig } from "@spt/models/spt/config/IHttpConfig"; import { ILocationConfig } from "@spt/models/spt/config/ILocationConfig"; import { IQuestConfig } from "@spt/models/spt/config/IQuestConfig"; -import { ISeasonalEvent, ISeasonalEventConfig, ISeasonalEventSettings, IZombieSettings } from "@spt/models/spt/config/ISeasonalEventConfig"; +import { + ISeasonalEvent, + ISeasonalEventConfig, + ISeasonalEventSettings, + IZombieSettings, +} from "@spt/models/spt/config/ISeasonalEventConfig"; import { IWeatherConfig } from "@spt/models/spt/config/IWeatherConfig"; import type { ILogger } from "@spt/models/spt/utils/ILogger"; import { ConfigServer } from "@spt/servers/ConfigServer"; diff --git a/project/src/tools/HideoutCustomisation/HideoutCustomisationGen.ts b/project/src/tools/HideoutCustomisation/HideoutCustomisationGen.ts index 849a0cd4..e4041283 100644 --- a/project/src/tools/HideoutCustomisation/HideoutCustomisationGen.ts +++ b/project/src/tools/HideoutCustomisation/HideoutCustomisationGen.ts @@ -70,7 +70,8 @@ export class HideoutCustomisationGen { } const matchingQuest = this.questCustomisationReward[questOrAchievementRequirement.target as string]; - const matchingAchievement = this.achievementCustomisationReward[questOrAchievementRequirement.target as string]; + const matchingAchievement = + this.achievementCustomisationReward[questOrAchievementRequirement.target as string]; let source = null; if (matchingQuest) { diff --git a/project/tests/CustomEnvironment.ts b/project/tests/CustomEnvironment.ts index 3b6865c3..a90b0a67 100644 --- a/project/tests/CustomEnvironment.ts +++ b/project/tests/CustomEnvironment.ts @@ -26,7 +26,7 @@ export default ({ await importDatabase(container); return { - async teardown() { }, + async teardown() {}, }; }, }); diff --git a/project/tsconfig.json b/project/tsconfig.json index 13e58971..fb3692db 100644 --- a/project/tsconfig.json +++ b/project/tsconfig.json @@ -13,16 +13,9 @@ "verbatimModuleSyntax": false, "baseUrl": ".", "paths": { - "@spt/*": [ - "./src/*" - ], - "@tests/*": [ - "./tests/*" - ] - }, + "@spt/*": ["./src/*"], + "@tests/*": ["./tests/*"] + } }, - "include": [ - "src/*", - "src/**/*" - ] + "include": ["src/*", "src/**/*"] } diff --git a/project/tsconfig.types.json b/project/tsconfig.types.json index c96fe95a..267b4eea 100644 --- a/project/tsconfig.types.json +++ b/project/tsconfig.types.json @@ -7,7 +7,5 @@ "declaration": true, "declarationDir": "./types" }, - "exclude": [ - "./types/**/*" - ] + "exclude": ["./types/**/*"] }