From fd56bf040ecbacb140860688f81214832bfc9eae Mon Sep 17 00:00:00 2001 From: Dev Date: Wed, 12 Jul 2023 20:12:16 +0100 Subject: [PATCH] Convert hideout craft exp magic string into config value --- project/assets/configs/hideout.json | 3 ++- project/src/controllers/HideoutController.ts | 2 +- project/src/models/spt/config/IHideoutConfig.ts | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/project/assets/configs/hideout.json b/project/assets/configs/hideout.json index 26fadb01..99b8f78d 100644 --- a/project/assets/configs/hideout.json +++ b/project/assets/configs/hideout.json @@ -1,5 +1,6 @@ { "runIntervalSeconds": 15, "hoursForSkillCrafting": 28800, - "hideoutWallAppearTimeSeconds": 86400 + "hideoutWallAppearTimeSeconds": 86400, + "expCraftAmount": 10 } \ No newline at end of file diff --git a/project/src/controllers/HideoutController.ts b/project/src/controllers/HideoutController.ts index 8e27b26b..3352e421 100644 --- a/project/src/controllers/HideoutController.ts +++ b/project/src/controllers/HideoutController.ts @@ -587,7 +587,7 @@ export class HideoutController if (area && request.recipeId !== area.lastRecipe) { // 1 point per craft upon the end of production for alternating between 2 different crafting recipes in the same module - craftingExpAmount += 10; + craftingExpAmount += this.hideoutConfig.expCraftAmount; // Default is 10 } // 1 point per 8 hours of crafting diff --git a/project/src/models/spt/config/IHideoutConfig.ts b/project/src/models/spt/config/IHideoutConfig.ts index 686450b7..836647d0 100644 --- a/project/src/models/spt/config/IHideoutConfig.ts +++ b/project/src/models/spt/config/IHideoutConfig.ts @@ -6,4 +6,5 @@ export interface IHideoutConfig extends IBaseConfig runIntervalSeconds: number hoursForSkillCrafting: number hideoutWallAppearTimeSeconds: number + expCraftAmount: number; } \ No newline at end of file