Updated various interfaces to use correct naming scheme

Added `IGroupPostion`
This commit is contained in:
Dev 2024-09-24 11:26:45 +01:00
parent 63774da653
commit 5fd9271491
40 changed files with 293 additions and 273 deletions

View File

@ -8,7 +8,7 @@ import { PreSptModLoader } from "@spt/loaders/PreSptModLoader";
import { IEmptyRequestData } from "@spt/models/eft/common/IEmptyRequestData"; import { IEmptyRequestData } from "@spt/models/eft/common/IEmptyRequestData";
import { ILocation } from "@spt/models/eft/common/ILocation"; import { ILocation } from "@spt/models/eft/common/ILocation";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { BodyPartHealth } from "@spt/models/eft/common/tables/IBotBase"; import { IBodyPartHealth } from "@spt/models/eft/common/tables/IBotBase";
import { ICheckVersionResponse } from "@spt/models/eft/game/ICheckVersionResponse"; import { ICheckVersionResponse } from "@spt/models/eft/game/ICheckVersionResponse";
import { ICurrentGroupResponse } from "@spt/models/eft/game/ICurrentGroupResponse"; import { ICurrentGroupResponse } from "@spt/models/eft/game/ICurrentGroupResponse";
import { IGameConfigResponse } from "@spt/models/eft/game/IGameConfigResponse"; import { IGameConfigResponse } from "@spt/models/eft/game/IGameConfigResponse";
@ -669,7 +669,7 @@ export class GameController {
// Check all body parts // Check all body parts
for (const bodyPartKey in pmcProfile.Health.BodyParts) { for (const bodyPartKey in pmcProfile.Health.BodyParts) {
const bodyPart = pmcProfile.Health.BodyParts[bodyPartKey] as BodyPartHealth; const bodyPart = pmcProfile.Health.BodyParts[bodyPartKey] as IBodyPartHealth;
// Check part hp // Check part hp
if (bodyPart.Health.Current < bodyPart.Health.Maximum) { if (bodyPart.Health.Current < bodyPart.Health.Maximum) {

View File

@ -6,7 +6,7 @@ import { PaymentHelper } from "@spt/helpers/PaymentHelper";
import { PresetHelper } from "@spt/helpers/PresetHelper"; import { PresetHelper } from "@spt/helpers/PresetHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { HideoutArea, ITaskConditionCounter, Product, ScavCase } from "@spt/models/eft/common/tables/IBotBase"; import { IBotHideoutArea, IProduct, IScavCase, ITaskConditionCounter } from "@spt/models/eft/common/tables/IBotBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { HideoutUpgradeCompleteRequestData } from "@spt/models/eft/hideout/HideoutUpgradeCompleteRequestData"; import { HideoutUpgradeCompleteRequestData } from "@spt/models/eft/hideout/HideoutUpgradeCompleteRequestData";
import { IHandleQTEEventRequestData } from "@spt/models/eft/hideout/IHandleQTEEventRequestData"; import { IHandleQTEEventRequestData } from "@spt/models/eft/hideout/IHandleQTEEventRequestData";
@ -270,7 +270,7 @@ export class HideoutController {
output: IItemEventRouterResponse, output: IItemEventRouterResponse,
sessionID: string, sessionID: string,
pmcData: IPmcData, pmcData: IPmcData,
profileParentHideoutArea: HideoutArea, profileParentHideoutArea: IBotHideoutArea,
dbHideoutArea: IHideoutArea, dbHideoutArea: IHideoutArea,
hideoutStage: Stage, hideoutStage: Stage,
): void { ): void {
@ -553,7 +553,7 @@ export class HideoutController {
pmcData: IPmcData, pmcData: IPmcData,
removeResourceRequest: IHideoutTakeItemOutRequestData, removeResourceRequest: IHideoutTakeItemOutRequestData,
output: IItemEventRouterResponse, output: IItemEventRouterResponse,
hideoutArea: HideoutArea, hideoutArea: IBotHideoutArea,
): IItemEventRouterResponse { ): IItemEventRouterResponse {
const slotIndexToRemove = removeResourceRequest.slots[0]; const slotIndexToRemove = removeResourceRequest.slots[0];
@ -749,7 +749,7 @@ export class HideoutController {
* @param rewards reward items to add to profile * @param rewards reward items to add to profile
* @param recipeId recipe id to save into Production dict * @param recipeId recipe id to save into Production dict
*/ */
protected addScavCaseRewardsToProfile(pmcData: IPmcData, rewards: Product[], recipeId: string): void { protected addScavCaseRewardsToProfile(pmcData: IPmcData, rewards: IProduct[], recipeId: string): void {
pmcData.Hideout.Production[`ScavCase${recipeId}`] = { Products: rewards }; pmcData.Hideout.Production[`ScavCase${recipeId}`] = { Products: rewards };
} }
@ -1085,7 +1085,7 @@ export class HideoutController {
for (const production of ongoingProductions) { for (const production of ongoingProductions) {
if (this.hideoutHelper.isProductionType(production[1])) { if (this.hideoutHelper.isProductionType(production[1])) {
// Production or ScavCase // Production or ScavCase
if ((production[1] as ScavCase).RecipeId === request.recipeId) { if ((production[1] as IScavCase).RecipeId === request.recipeId) {
prodId = production[0]; // Set to objects key prodId = production[0]; // Set to objects key
break; break;
} }

View File

@ -1,5 +1,5 @@
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { Note } from "@spt/models/eft/common/tables/IBotBase"; import { INote } from "@spt/models/eft/common/tables/IBotBase";
import { IItemEventRouterResponse } from "@spt/models/eft/itemEvent/IItemEventRouterResponse"; import { IItemEventRouterResponse } from "@spt/models/eft/itemEvent/IItemEventRouterResponse";
import { INoteActionData } from "@spt/models/eft/notes/INoteActionData"; import { INoteActionData } from "@spt/models/eft/notes/INoteActionData";
import { EventOutputHolder } from "@spt/routers/EventOutputHolder"; import { EventOutputHolder } from "@spt/routers/EventOutputHolder";
@ -10,14 +10,14 @@ export class NoteController {
constructor(@inject("EventOutputHolder") protected eventOutputHolder: EventOutputHolder) {} constructor(@inject("EventOutputHolder") protected eventOutputHolder: EventOutputHolder) {}
public addNote(pmcData: IPmcData, body: INoteActionData, sessionID: string): IItemEventRouterResponse { public addNote(pmcData: IPmcData, body: INoteActionData, sessionID: string): IItemEventRouterResponse {
const newNote: Note = { Time: body.note.Time, Text: body.note.Text }; const newNote: INote = { Time: body.note.Time, Text: body.note.Text };
pmcData.Notes.Notes.push(newNote); pmcData.Notes.Notes.push(newNote);
return this.eventOutputHolder.getOutput(sessionID); return this.eventOutputHolder.getOutput(sessionID);
} }
public editNote(pmcData: IPmcData, body: INoteActionData, sessionID: string): IItemEventRouterResponse { public editNote(pmcData: IPmcData, body: INoteActionData, sessionID: string): IItemEventRouterResponse {
const noteToEdit: Note = pmcData.Notes.Notes[body.index]; const noteToEdit: INote = pmcData.Notes.Notes[body.index];
noteToEdit.Time = body.note.Time; noteToEdit.Time = body.note.Time;
noteToEdit.Text = body.note.Text; noteToEdit.Text = body.note.Text;

View File

@ -9,9 +9,9 @@ import {
IBaseJsonSkills, IBaseJsonSkills,
IBaseSkill, IBaseSkill,
IBotBase, IBotBase,
Info, IInfo,
Health as PmcHealth, IHealth as PmcHealth,
Skills as botSkills, ISkills as botSkills,
} from "@spt/models/eft/common/tables/IBotBase"; } from "@spt/models/eft/common/tables/IBotBase";
import { Appearance, BodyPart, Health, IBotType, Inventory } from "@spt/models/eft/common/tables/IBotType"; import { Appearance, BodyPart, Health, IBotType, Inventory } from "@spt/models/eft/common/tables/IBotType";
import { Item, Upd } from "@spt/models/eft/common/tables/IItem"; import { Item, Upd } from "@spt/models/eft/common/tables/IItem";
@ -516,7 +516,7 @@ export class BotGenerator {
* @param botInfo bot info object to update * @param botInfo bot info object to update
* @returns Chosen game version * @returns Chosen game version
*/ */
protected setRandomisedGameVersionAndCategory(botInfo: Info): string { protected setRandomisedGameVersionAndCategory(botInfo: IInfo): string {
// Special case // Special case
if (botInfo.Nickname?.toLowerCase() === "nikita") { if (botInfo.Nickname?.toLowerCase() === "nikita") {
botInfo.GameVersion = GameEditions.UNHEARD; botInfo.GameVersion = GameEditions.UNHEARD;

View File

@ -5,7 +5,7 @@ import { BotGeneratorHelper } from "@spt/helpers/BotGeneratorHelper";
import { BotHelper } from "@spt/helpers/BotHelper"; import { BotHelper } from "@spt/helpers/BotHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper"; import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper";
import { Inventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase";
import { Chances, Equipment, Generation, IBotType, Inventory } from "@spt/models/eft/common/tables/IBotType"; import { Chances, Equipment, Generation, IBotType, Inventory } from "@spt/models/eft/common/tables/IBotType";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";

View File

@ -5,7 +5,7 @@ import { HandbookHelper } from "@spt/helpers/HandbookHelper";
import { InventoryHelper } from "@spt/helpers/InventoryHelper"; import { InventoryHelper } from "@spt/helpers/InventoryHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper"; import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper";
import { Inventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase";
import { IBotType, Inventory, ModsChances } from "@spt/models/eft/common/tables/IBotType"; import { IBotType, Inventory, ModsChances } from "@spt/models/eft/common/tables/IBotType";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";

View File

@ -6,7 +6,7 @@ import { BotWeaponGeneratorHelper } from "@spt/helpers/BotWeaponGeneratorHelper"
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper"; import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper";
import { IPreset } from "@spt/models/eft/common/IGlobals"; import { IPreset } from "@spt/models/eft/common/IGlobals";
import { Inventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase";
import { GenerationData, Inventory, ModsChances } from "@spt/models/eft/common/tables/IBotType"; import { GenerationData, Inventory, ModsChances } from "@spt/models/eft/common/tables/IBotType";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";

View File

@ -10,7 +10,7 @@ import {
IStaticLootDetails, IStaticLootDetails,
} from "@spt/models/eft/common/ILocation"; } from "@spt/models/eft/common/ILocation";
import { ILocationBase } from "@spt/models/eft/common/ILocationBase"; import { ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { ILooseLoot, Spawnpoint, SpawnpointTemplate, SpawnpointsForced } from "@spt/models/eft/common/ILooseLoot"; import { ILooseLoot, ISpawnpoint, ISpawnpointTemplate, ISpawnpointsForced } from "@spt/models/eft/common/ILooseLoot";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { BaseClasses } from "@spt/models/enums/BaseClasses"; import { BaseClasses } from "@spt/models/enums/BaseClasses";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
@ -71,9 +71,9 @@ export class LocationLootGenerator {
public generateStaticContainers( public generateStaticContainers(
locationBase: ILocationBase, locationBase: ILocationBase,
staticAmmoDist: Record<string, IStaticAmmoDetails[]>, staticAmmoDist: Record<string, IStaticAmmoDetails[]>,
): SpawnpointTemplate[] { ): ISpawnpointTemplate[] {
let staticLootItemCount = 0; let staticLootItemCount = 0;
const result: SpawnpointTemplate[] = []; const result: ISpawnpointTemplate[] = [];
const locationId = locationBase.Id.toLowerCase(); const locationId = locationBase.Id.toLowerCase();
const mapData = this.databaseService.getLocation(locationId); const mapData = this.databaseService.getLocation(locationId);
@ -575,9 +575,9 @@ export class LocationLootGenerator {
dynamicLootDist: ILooseLoot, dynamicLootDist: ILooseLoot,
staticAmmoDist: Record<string, IStaticAmmoDetails[]>, staticAmmoDist: Record<string, IStaticAmmoDetails[]>,
locationName: string, locationName: string,
): SpawnpointTemplate[] { ): ISpawnpointTemplate[] {
const loot: SpawnpointTemplate[] = []; const loot: ISpawnpointTemplate[] = [];
const dynamicForcedSpawnPoints: SpawnpointsForced[] = []; const dynamicForcedSpawnPoints: ISpawnpointsForced[] = [];
// Build the list of forced loot from both `spawnpointsForced` and any point marked `IsAlwaysSpawn` // Build the list of forced loot from both `spawnpointsForced` and any point marked `IsAlwaysSpawn`
dynamicForcedSpawnPoints.push(...dynamicLootDist.spawnpointsForced); dynamicForcedSpawnPoints.push(...dynamicLootDist.spawnpointsForced);
@ -598,10 +598,10 @@ export class LocationLootGenerator {
); );
// Positions not in forced but have 100% chance to spawn // Positions not in forced but have 100% chance to spawn
const guaranteedLoosePoints: Spawnpoint[] = []; const guaranteedLoosePoints: ISpawnpoint[] = [];
const blacklistedSpawnpoints = this.locationConfig.looseLootBlacklist[locationName]; const blacklistedSpawnpoints = this.locationConfig.looseLootBlacklist[locationName];
const spawnpointArray = new ProbabilityObjectArray<string, Spawnpoint>(this.mathUtil, this.cloner); const spawnpointArray = new ProbabilityObjectArray<string, ISpawnpoint>(this.mathUtil, this.cloner);
for (const spawnpoint of allDynamicSpawnpoints) { for (const spawnpoint of allDynamicSpawnpoints) {
// Point is blacklsited, skip // Point is blacklsited, skip
@ -626,7 +626,7 @@ export class LocationLootGenerator {
// Select a number of spawn points to add loot to // Select a number of spawn points to add loot to
// Add ALL loose loot with 100% chance to pool // Add ALL loose loot with 100% chance to pool
let chosenSpawnpoints: Spawnpoint[] = [...guaranteedLoosePoints]; let chosenSpawnpoints: ISpawnpoint[] = [...guaranteedLoosePoints];
const randomSpawnpointCount = desiredSpawnpointCount - chosenSpawnpoints.length; const randomSpawnpointCount = desiredSpawnpointCount - chosenSpawnpoints.length;
// Only draw random spawn points if needed // Only draw random spawn points if needed
@ -732,8 +732,8 @@ export class LocationLootGenerator {
* @param locationName Name of map currently having force loot created for * @param locationName Name of map currently having force loot created for
*/ */
protected addForcedLoot( protected addForcedLoot(
lootLocationTemplates: SpawnpointTemplate[], lootLocationTemplates: ISpawnpointTemplate[],
forcedSpawnPoints: SpawnpointsForced[], forcedSpawnPoints: ISpawnpointsForced[],
locationName: string, locationName: string,
): void { ): void {
const lootToForceSingleAmountOnMap = this.locationConfig.forcedLootSingleSpawnById[locationName]; const lootToForceSingleAmountOnMap = this.locationConfig.forcedLootSingleSpawnById[locationName];
@ -752,7 +752,7 @@ export class LocationLootGenerator {
} }
// Create probability array of all spawn positions for this spawn id // Create probability array of all spawn positions for this spawn id
const spawnpointArray = new ProbabilityObjectArray<string, SpawnpointsForced>( const spawnpointArray = new ProbabilityObjectArray<string, ISpawnpointsForced>(
this.mathUtil, this.mathUtil,
this.cloner, this.cloner,
); );
@ -824,7 +824,7 @@ export class LocationLootGenerator {
*/ */
protected createDynamicLootItem( protected createDynamicLootItem(
chosenComposedKey: string, chosenComposedKey: string,
spawnPoint: Spawnpoint, spawnPoint: ISpawnpoint,
staticAmmoDist: Record<string, IStaticAmmoDetails[]>, staticAmmoDist: Record<string, IStaticAmmoDetails[]>,
): IContainerItem { ): IContainerItem {
const chosenItem = spawnPoint.template.Items.find((item) => item._id === chosenComposedKey); const chosenItem = spawnPoint.template.Items.find((item) => item._id === chosenComposedKey);

View File

@ -4,7 +4,7 @@ import { BotHelper } from "@spt/helpers/BotHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { IBotBase, Settings, Skills, Stats } from "@spt/models/eft/common/tables/IBotBase"; import { IBotBase, IBotInfoSettings, ISkills, IStats } from "@spt/models/eft/common/tables/IBotBase";
import { IBotType } from "@spt/models/eft/common/tables/IBotType"; import { IBotType } from "@spt/models/eft/common/tables/IBotType";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { AccountTypes } from "@spt/models/enums/AccountTypes"; import { AccountTypes } from "@spt/models/enums/AccountTypes";
@ -89,7 +89,7 @@ export class PlayerScavGenerator {
scavData.savage = undefined; scavData.savage = undefined;
scavData.aid = pmcDataClone.aid; scavData.aid = pmcDataClone.aid;
scavData.TradersInfo = pmcDataClone.TradersInfo; scavData.TradersInfo = pmcDataClone.TradersInfo;
scavData.Info.Settings = {} as Settings; scavData.Info.Settings = {} as IBotInfoSettings;
scavData.Info.Bans = []; scavData.Info.Bans = [];
scavData.Info.RegistrationDate = pmcDataClone.Info.RegistrationDate; scavData.Info.RegistrationDate = pmcDataClone.Info.RegistrationDate;
scavData.Info.GameVersion = pmcDataClone.Info.GameVersion; scavData.Info.GameVersion = pmcDataClone.Info.GameVersion;
@ -262,7 +262,7 @@ export class PlayerScavGenerator {
} }
} }
protected getScavSkills(scavProfile: IPmcData): Skills { protected getScavSkills(scavProfile: IPmcData): ISkills {
if (scavProfile.Skills) { if (scavProfile.Skills) {
return scavProfile.Skills; return scavProfile.Skills;
} }
@ -270,11 +270,11 @@ export class PlayerScavGenerator {
return this.getDefaultScavSkills(); return this.getDefaultScavSkills();
} }
protected getDefaultScavSkills(): Skills { protected getDefaultScavSkills(): ISkills {
return { Common: [], Mastering: [], Points: 0 }; return { Common: [], Mastering: [], Points: 0 };
} }
protected getScavStats(scavProfile: IPmcData): Stats { protected getScavStats(scavProfile: IPmcData): IStats {
if (scavProfile.Stats) { if (scavProfile.Stats) {
return scavProfile.Stats; return scavProfile.Stats;
} }

View File

@ -1,8 +1,8 @@
import { RepeatableQuestRewardGenerator } from "@spt/generators/RepeatableQuestRewardGenerator"; import { RepeatableQuestRewardGenerator } from "@spt/generators/RepeatableQuestRewardGenerator";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { RepeatableQuestHelper } from "@spt/helpers/RepeatableQuestHelper"; import { RepeatableQuestHelper } from "@spt/helpers/RepeatableQuestHelper";
import { Exit } from "@spt/models/eft/common/ILocationBase"; import { IExit } from "@spt/models/eft/common/ILocationBase";
import { TraderInfo } from "@spt/models/eft/common/tables/IBotBase"; import { ITraderInfo } from "@spt/models/eft/common/tables/IBotBase";
import { IQuestCondition, IQuestConditionCounterCondition } from "@spt/models/eft/common/tables/IQuest"; import { IQuestCondition, IQuestConditionCounterCondition } from "@spt/models/eft/common/tables/IQuest";
import { IRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests"; import { IRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests";
import { BaseClasses } from "@spt/models/enums/BaseClasses"; import { BaseClasses } from "@spt/models/enums/BaseClasses";
@ -58,7 +58,7 @@ export class RepeatableQuestGenerator {
*/ */
public generateRepeatableQuest( public generateRepeatableQuest(
pmcLevel: number, pmcLevel: number,
pmcTraderInfo: Record<string, TraderInfo>, pmcTraderInfo: Record<string, ITraderInfo>,
questTypePool: IQuestTypePool, questTypePool: IQuestTypePool,
repeatableConfig: IRepeatableQuestConfig, repeatableConfig: IRepeatableQuestConfig,
): IRepeatableQuest { ): IRepeatableQuest {
@ -748,7 +748,7 @@ export class RepeatableQuestGenerator {
* @param playerSide Scav/Pmc * @param playerSide Scav/Pmc
* @returns Array of Exit objects * @returns Array of Exit objects
*/ */
protected getLocationExitsForSide(locationKey: string, playerSide: string): Exit[] { protected getLocationExitsForSide(locationKey: string, playerSide: string): IExit[] {
const mapExtracts = this.databaseService.getLocation(locationKey.toLocaleLowerCase()).allExtracts; const mapExtracts = this.databaseService.getLocation(locationKey.toLocaleLowerCase()).allExtracts;
return mapExtracts.filter((exit) => exit.Side === playerSide); return mapExtracts.filter((exit) => exit.Side === playerSide);
@ -816,7 +816,7 @@ export class RepeatableQuestGenerator {
* @param {string} exit The exit name to generate the condition for * @param {string} exit The exit name to generate the condition for
* @returns {object} Exit condition * @returns {object} Exit condition
*/ */
protected generateExplorationExitCondition(exit: Exit): IQuestConditionCounterCondition { protected generateExplorationExitCondition(exit: IExit): IQuestConditionCounterCondition {
return { conditionType: "ExitName", exitName: exit.Name, id: this.objectId.generate(), dynamicLocale: true }; return { conditionType: "ExitName", exitName: exit.Name, id: this.objectId.generate(), dynamicLocale: true };
} }

View File

@ -1,4 +1,4 @@
import { Inventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory } from "@spt/models/eft/common/tables/IBotBase";
import { GenerationData } from "@spt/models/eft/common/tables/IBotType"; import { GenerationData } from "@spt/models/eft/common/tables/IBotType";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";
@ -8,7 +8,7 @@ export class InventoryMagGen {
private magazineTemplate: ITemplateItem, private magazineTemplate: ITemplateItem,
private weaponTemplate: ITemplateItem, private weaponTemplate: ITemplateItem,
private ammoTemplate: ITemplateItem, private ammoTemplate: ITemplateItem,
private pmcInventory: Inventory, private pmcInventory: IInventory,
) {} ) {}
public getMagCount(): GenerationData { public getMagCount(): GenerationData {
@ -27,7 +27,7 @@ export class InventoryMagGen {
return this.ammoTemplate; return this.ammoTemplate;
} }
public getPmcInventory(): Inventory { public getPmcInventory(): IInventory {
return this.pmcInventory; return this.pmcInventory;
} }
} }

View File

@ -4,7 +4,7 @@ import { ContainerHelper } from "@spt/helpers/ContainerHelper";
import { DurabilityLimitsHelper } from "@spt/helpers/DurabilityLimitsHelper"; import { DurabilityLimitsHelper } from "@spt/helpers/DurabilityLimitsHelper";
import { InventoryHelper } from "@spt/helpers/InventoryHelper"; import { InventoryHelper } from "@spt/helpers/InventoryHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { Inventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory } from "@spt/models/eft/common/tables/IBotBase";
import { Item, Repairable, Upd } from "@spt/models/eft/common/tables/IItem"; import { Item, Repairable, Upd } from "@spt/models/eft/common/tables/IItem";
import { Grid, ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { Grid, ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";
import { IGetRaidConfigurationRequestData } from "@spt/models/eft/match/IGetRaidConfigurationRequestData"; import { IGetRaidConfigurationRequestData } from "@spt/models/eft/match/IGetRaidConfigurationRequestData";
@ -412,7 +412,7 @@ export class BotGeneratorHelper {
rootItemId: string, rootItemId: string,
rootItemTplId: string, rootItemTplId: string,
itemWithChildren: Item[], itemWithChildren: Item[],
inventory: Inventory, inventory: IInventory,
containersIdFull?: Set<string>, containersIdFull?: Set<string>,
): ItemAddedResult { ): ItemAddedResult {
/** Track how many containers are unable to be found */ /** Track how many containers are unable to be found */

View File

@ -1,7 +1,7 @@
import { BotGeneratorHelper } from "@spt/helpers/BotGeneratorHelper"; import { BotGeneratorHelper } from "@spt/helpers/BotGeneratorHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper"; import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper";
import { Inventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory } from "@spt/models/eft/common/tables/IBotBase";
import { GenerationData } from "@spt/models/eft/common/tables/IBotType"; import { GenerationData } from "@spt/models/eft/common/tables/IBotType";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";
@ -103,7 +103,7 @@ export class BotWeaponGeneratorHelper {
public addAmmoIntoEquipmentSlots( public addAmmoIntoEquipmentSlots(
ammoTpl: string, ammoTpl: string,
cartridgeCount: number, cartridgeCount: number,
inventory: Inventory, inventory: IInventory,
equipmentSlotsToAddTo: EquipmentSlots[] = [EquipmentSlots.TACTICAL_VEST, EquipmentSlots.POCKETS], equipmentSlotsToAddTo: EquipmentSlots[] = [EquipmentSlots.TACTICAL_VEST, EquipmentSlots.POCKETS],
): void { ): void {
const ammoItems = this.itemHelper.splitStack({ const ammoItems = this.itemHelper.splitStack({

View File

@ -1,5 +1,5 @@
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { BodyPartsHealth, Health } from "@spt/models/eft/common/tables/IBotBase"; import { IBodyPartsHealth, IHealth } from "@spt/models/eft/common/tables/IBotBase";
import { ISyncHealthRequestData } from "@spt/models/eft/health/ISyncHealthRequestData"; import { ISyncHealthRequestData } from "@spt/models/eft/health/ISyncHealthRequestData";
import { Effects, ISptProfile } from "@spt/models/eft/profile/ISptProfile"; import { Effects, ISptProfile } from "@spt/models/eft/profile/ISptProfile";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
@ -74,7 +74,7 @@ export class HealthHelper {
*/ */
public updateProfileHealthPostRaid( public updateProfileHealthPostRaid(
pmcData: IPmcData, pmcData: IPmcData,
postRaidHealth: Health, postRaidHealth: IHealth,
sessionID: string, sessionID: string,
isDead: boolean, isDead: boolean,
): void { ): void {
@ -132,7 +132,7 @@ export class HealthHelper {
* @param postRaidBodyParts Post-raid body part data * @param postRaidBodyParts Post-raid body part data
* @param profileData Player profile on server * @param profileData Player profile on server
*/ */
protected transferPostRaidLimbEffectsToProfile(postRaidBodyParts: BodyPartsHealth, profileData: IPmcData): void { protected transferPostRaidLimbEffectsToProfile(postRaidBodyParts: IBodyPartsHealth, profileData: IPmcData): void {
// Iterate over each body part // Iterate over each body part
const effectsToIgnore = ["Dehydration", "Exhaustion"]; const effectsToIgnore = ["Dehydration", "Exhaustion"];
for (const bodyPartId in postRaidBodyParts) { for (const bodyPartId in postRaidBodyParts) {

View File

@ -2,7 +2,7 @@ import { InventoryHelper } from "@spt/helpers/InventoryHelper";
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { HideoutArea, IHideoutImprovement, Production, Productive } from "@spt/models/eft/common/tables/IBotBase"; import { IBotHideoutArea, IHideoutImprovement, IProduction, IProductive } from "@spt/models/eft/common/tables/IBotBase";
import { Item, Upd } from "@spt/models/eft/common/tables/IItem"; import { Item, Upd } from "@spt/models/eft/common/tables/IItem";
import { IHideoutArea, StageBonus } from "@spt/models/eft/hideout/IHideoutArea"; import { IHideoutArea, StageBonus } from "@spt/models/eft/hideout/IHideoutArea";
import { IHideoutContinuousProductionStartRequestData } from "@spt/models/eft/hideout/IHideoutContinuousProductionStartRequestData"; import { IHideoutContinuousProductionStartRequestData } from "@spt/models/eft/hideout/IHideoutContinuousProductionStartRequestData";
@ -126,7 +126,7 @@ export class HideoutHelper {
productionTime: number, productionTime: number,
needFuelForAllProductionTime: boolean, needFuelForAllProductionTime: boolean,
isCultistCircle = false, isCultistCircle = false,
): Production { ): IProduction {
return { return {
Progress: 0, Progress: 0,
inProgress: true, inProgress: true,
@ -148,8 +148,8 @@ export class HideoutHelper {
* @param productive * @param productive
* @returns * @returns
*/ */
public isProductionType(productive: Productive): productive is Production { public isProductionType(productive: IProductive): productive is IProduction {
return (productive as Production).Progress !== undefined || (productive as Production).RecipeId !== undefined; return (productive as IProduction).Progress !== undefined || (productive as IProduction).RecipeId !== undefined;
} }
/** /**
@ -231,7 +231,7 @@ export class HideoutHelper {
return hideoutProperties; return hideoutProperties;
} }
protected doesWaterCollectorHaveFilter(waterCollector: HideoutArea): boolean { protected doesWaterCollectorHaveFilter(waterCollector: IBotHideoutArea): boolean {
// Can put filters in from L3 // Can put filters in from L3
if (waterCollector.level === 3) { if (waterCollector.level === 3) {
// Has filter in at least one slot // Has filter in at least one slot
@ -396,7 +396,7 @@ export class HideoutHelper {
this.flagCultistCircleCraftAsComplete(production); this.flagCultistCircleCraftAsComplete(production);
} }
protected flagCultistCircleCraftAsComplete(production: Productive) { protected flagCultistCircleCraftAsComplete(production: IProductive) {
// Craft is complete, flas as such // Craft is complete, flas as such
production.AvailableForFinish = true; production.AvailableForFinish = true;
@ -465,7 +465,7 @@ export class HideoutHelper {
* @param pmcData Player profile * @param pmcData Player profile
* @param isGeneratorOn Is the generator turned on since last update * @param isGeneratorOn Is the generator turned on since last update
*/ */
protected updateFuel(generatorArea: HideoutArea, pmcData: IPmcData, isGeneratorOn: boolean): void { protected updateFuel(generatorArea: IBotHideoutArea, pmcData: IPmcData, isGeneratorOn: boolean): void {
// 1 resource last 14 min 27 sec, 1/14.45/60 = 0.00115 // 1 resource last 14 min 27 sec, 1/14.45/60 = 0.00115
// 10-10-2021 From wiki, 1 resource last 12 minutes 38 seconds, 1/12.63333/60 = 0.00131 // 10-10-2021 From wiki, 1 resource last 12 minutes 38 seconds, 1/12.63333/60 = 0.00131
let fuelUsedSinceLastTick = let fuelUsedSinceLastTick =
@ -565,7 +565,7 @@ export class HideoutHelper {
protected updateWaterCollector( protected updateWaterCollector(
sessionId: string, sessionId: string,
pmcData: IPmcData, pmcData: IPmcData,
area: HideoutArea, area: IBotHideoutArea,
hideoutProperties: { btcFarmCGs: number; isGeneratorOn: boolean; waterCollectorHasFilter: boolean }, hideoutProperties: { btcFarmCGs: number; isGeneratorOn: boolean; waterCollectorHasFilter: boolean },
): void { ): void {
// Skip water collector when not level 3 (cant collect until 3) // Skip water collector when not level 3 (cant collect until 3)
@ -670,8 +670,8 @@ export class HideoutHelper {
* @param pmcData Player profile * @param pmcData Player profile
*/ */
protected updateWaterFilters( protected updateWaterFilters(
waterFilterArea: HideoutArea, waterFilterArea: IBotHideoutArea,
production: Production, production: IProduction,
isGeneratorOn: boolean, isGeneratorOn: boolean,
pmcData: IPmcData, pmcData: IPmcData,
): void { ): void {
@ -837,7 +837,7 @@ export class HideoutHelper {
}; };
} }
protected updateAirFilters(airFilterArea: HideoutArea, pmcData: IPmcData, isGeneratorOn: boolean): void { protected updateAirFilters(airFilterArea: IBotHideoutArea, pmcData: IPmcData, isGeneratorOn: boolean): void {
// 300 resources last 20 hrs, 300/20/60/60 = 0.00416 // 300 resources last 20 hrs, 300/20/60/60 = 0.00416
/* 10-10-2021 from WIKI (https://escapefromtarkov.fandom.com/wiki/FP-100_filter_absorber) /* 10-10-2021 from WIKI (https://escapefromtarkov.fandom.com/wiki/FP-100_filter_absorber)
Lasts for 17 hours 38 minutes and 49 seconds (23 hours 31 minutes and 45 seconds with elite hideout management skill), Lasts for 17 hours 38 minutes and 49 seconds (23 hours 31 minutes and 45 seconds with elite hideout management skill),
@ -891,7 +891,7 @@ export class HideoutHelper {
protected updateBitcoinFarm( protected updateBitcoinFarm(
pmcData: IPmcData, pmcData: IPmcData,
btcProduction: Productive, btcProduction: IProductive,
btcFarmCGs: number, btcFarmCGs: number,
isGeneratorOn: boolean, isGeneratorOn: boolean,
): void { ): void {
@ -982,7 +982,7 @@ export class HideoutHelper {
* @param btcProd Bitcoin production object * @param btcProd Bitcoin production object
* @param coinCraftTimeSeconds Time to craft a bitcoin * @param coinCraftTimeSeconds Time to craft a bitcoin
*/ */
protected addBtcToProduction(btcProd: Production, coinCraftTimeSeconds: number): void { protected addBtcToProduction(btcProd: IProduction, coinCraftTimeSeconds: number): void {
btcProd.Products.push({ btcProd.Products.push({
_id: this.hashUtil.generate(), _id: this.hashUtil.generate(),
_tpl: ItemTpl.BARTER_PHYSICAL_BITCOIN, _tpl: ItemTpl.BARTER_PHYSICAL_BITCOIN,
@ -1113,8 +1113,8 @@ export class HideoutHelper {
return productionTime * skillTimeReductionMultipler; return productionTime * skillTimeReductionMultipler;
} }
public isProduction(productive: Productive): productive is Production { public isProduction(productive: IProductive): productive is IProduction {
return (productive as Production).Progress !== undefined || (productive as Production).RecipeId !== undefined; return (productive as IProduction).Progress !== undefined || (productive as IProduction).RecipeId !== undefined;
} }
/** /**

View File

@ -6,7 +6,7 @@ import { PresetHelper } from "@spt/helpers/PresetHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { TraderAssortHelper } from "@spt/helpers/TraderAssortHelper"; import { TraderAssortHelper } from "@spt/helpers/TraderAssortHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { Inventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory } from "@spt/models/eft/common/tables/IBotBase";
import { Item, Location, Upd } from "@spt/models/eft/common/tables/IItem"; import { Item, Location, Upd } from "@spt/models/eft/common/tables/IItem";
import { IAddItemDirectRequest } from "@spt/models/eft/inventory/IAddItemDirectRequest"; import { IAddItemDirectRequest } from "@spt/models/eft/inventory/IAddItemDirectRequest";
import { IAddItemsDirectRequest } from "@spt/models/eft/inventory/IAddItemsDirectRequest"; import { IAddItemsDirectRequest } from "@spt/models/eft/inventory/IAddItemsDirectRequest";
@ -345,7 +345,7 @@ export class InventoryHelper {
stashFS2D: number[][], stashFS2D: number[][],
sortingTableFS2D: number[][], sortingTableFS2D: number[][],
itemWithChildren: Item[], itemWithChildren: Item[],
playerInventory: Inventory, playerInventory: IInventory,
useSortingTable: boolean, useSortingTable: boolean,
output: IItemEventRouterResponse, output: IItemEventRouterResponse,
): void { ): void {

View File

@ -1,6 +1,6 @@
import { ItemHelper } from "@spt/helpers/ItemHelper"; import { ItemHelper } from "@spt/helpers/ItemHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { BanType, Common, CounterKeyValue, Stats } from "@spt/models/eft/common/tables/IBotBase"; import { BanType, Common, ICounterKeyValue, IStats } from "@spt/models/eft/common/tables/IBotBase";
import { ISptProfile } from "@spt/models/eft/profile/ISptProfile"; import { ISptProfile } from "@spt/models/eft/profile/ISptProfile";
import { IValidateNicknameRequestData } from "@spt/models/eft/profile/IValidateNicknameRequestData"; import { IValidateNicknameRequestData } from "@spt/models/eft/profile/IValidateNicknameRequestData";
import { AccountTypes } from "@spt/models/enums/AccountTypes"; import { AccountTypes } from "@spt/models/enums/AccountTypes";
@ -276,7 +276,7 @@ export class ProfileHelper {
* Get baseline counter values for a fresh profile * Get baseline counter values for a fresh profile
* @returns Default profile Stats object * @returns Default profile Stats object
*/ */
public getDefaultCounters(): Stats { public getDefaultCounters(): IStats {
return { return {
Eft: { Eft: {
CarriedQuestItems: [], CarriedQuestItems: [],
@ -388,7 +388,7 @@ export class ProfileHelper {
* @param counters Counters to search for key * @param counters Counters to search for key
* @param keyToIncrement Key * @param keyToIncrement Key
*/ */
public incrementStatCounter(counters: CounterKeyValue[], keyToIncrement: string): void { public incrementStatCounter(counters: ICounterKeyValue[], keyToIncrement: string): void {
const stat = counters.find((x) => x.Key.includes(keyToIncrement)); const stat = counters.find((x) => x.Key.includes(keyToIncrement));
if (stat) { if (stat) {
stat.Value++; stat.Value++;

View File

@ -1,5 +1,5 @@
import { Exit, ILocationBase } from "@spt/models/eft/common/ILocationBase"; import { IExit, ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { ILooseLoot } from "@spt/models/eft/common/ILooseLoot"; import { IGroupPostion, ILooseLoot } from "@spt/models/eft/common/ILooseLoot";
import { Ixyz } from "@spt/models/eft/common/Ixyz"; import { Ixyz } from "@spt/models/eft/common/Ixyz";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
@ -16,7 +16,7 @@ export interface ILocation {
/** All possible static containers on map + their assign groupings */ /** All possible static containers on map + their assign groupings */
statics: IStaticContainer; statics: IStaticContainer;
/** All possible map extracts */ /** All possible map extracts */
allExtracts: Exit[]; allExtracts: IExit[];
} }
export interface IStaticContainer { export interface IStaticContainer {
@ -59,9 +59,9 @@ export interface IStaticPropsBase {
Rotation: Ixyz; Rotation: Ixyz;
IsGroupPosition: boolean; IsGroupPosition: boolean;
IsAlwaysSpawn: boolean; IsAlwaysSpawn: boolean;
GroupPositions: any[]; GroupPositions: IGroupPostion[];
Root: string; Root: string;
Items: any[]; Items: Item[];
} }
export interface IStaticWeaponProps extends IStaticPropsBase { export interface IStaticWeaponProps extends IStaticPropsBase {
@ -90,10 +90,10 @@ export interface IStaticForcedProps {
} }
export interface IStaticContainerProps extends IStaticPropsBase { export interface IStaticContainerProps extends IStaticPropsBase {
Items: StaticItem[]; Items: IStaticItem[];
} }
export interface StaticItem { export interface IStaticItem {
_id: string; _id: string;
_tpl: string; _tpl: string;
} }

View File

@ -1,19 +1,20 @@
import { MinMax } from "@spt/models/common/MinMax"; import { MinMax } from "@spt/models/common/MinMax";
import { Ixyz } from "@spt/models/eft/common/Ixyz"; import { Ixyz } from "@spt/models/eft/common/Ixyz";
import { ISpawnpointTemplate } from "./ILooseLoot";
export interface ILocationBase { export interface ILocationBase {
AccessKeys: string[]; AccessKeys: string[];
AirdropParameters: AirdropParameter[]; AirdropParameters: IAirdropParameter[];
Area: number; Area: number;
AveragePlayTime: number; AveragePlayTime: number;
AveragePlayerLevel: number; AveragePlayerLevel: number;
Banners: Banner[]; Banners: IBanner[];
BossLocationSpawn: BossLocationSpawn[]; BossLocationSpawn: IBossLocationSpawn[];
BotAssault: number; BotAssault: number;
BotEasy: number; BotEasy: number;
BotHard: number; BotHard: number;
BotImpossible: number; BotImpossible: number;
BotLocationModifier: BotLocationModifier; BotLocationModifier: IBotLocationModifier;
BotMarksman: number; BotMarksman: number;
BotMax: number; BotMax: number;
BotMaxPlayer: number; BotMaxPlayer: number;
@ -42,14 +43,14 @@ export interface ILocationBase {
Insurance: boolean; Insurance: boolean;
IsSecret: boolean; IsSecret: boolean;
Locked: boolean; Locked: boolean;
Loot: any[]; Loot: ISpawnpointTemplate[];
MatchMakerMinPlayersByWaitTime: MinPlayerWaitTime[]; MatchMakerMinPlayersByWaitTime: IMinPlayerWaitTime[];
MaxBotPerZone: number; MaxBotPerZone: number;
MaxDistToFreePoint: number; MaxDistToFreePoint: number;
MaxPlayers: number; MaxPlayers: number;
MinDistToExitPoint: number; MinDistToExitPoint: number;
MinDistToFreePoint: number; MinDistToFreePoint: number;
MinMaxBots: MinMaxBot[]; MinMaxBots: IMinMaxBot[];
MinPlayers: number; MinPlayers: number;
MaxCoopGroup: number; MaxCoopGroup: number;
Name: string; Name: string;
@ -58,7 +59,7 @@ export interface ILocationBase {
OcculsionCullingEnabled: boolean; OcculsionCullingEnabled: boolean;
OldSpawn: boolean; OldSpawn: boolean;
OpenZones: string; OpenZones: string;
Preview: Preview; Preview: IPreview;
PlayersRequestCount: number; PlayersRequestCount: number;
RequiredPlayerLevel?: number; RequiredPlayerLevel?: number;
RequiredPlayerLevelMin?: number; RequiredPlayerLevelMin?: number;
@ -68,8 +69,8 @@ export interface ILocationBase {
ScavMaxPlayersInGroup: number; ScavMaxPlayersInGroup: number;
Rules: string; Rules: string;
SafeLocation: boolean; SafeLocation: boolean;
Scene: Scene; Scene: IScene;
SpawnPointParams: SpawnPointParam[]; SpawnPointParams: ISpawnPointParam[];
UnixDateTime: number; UnixDateTime: number;
_Id: string; _Id: string;
doors: any[]; doors: any[];
@ -80,12 +81,12 @@ export interface ILocationBase {
ForceOnlineRaidInPVE: boolean; ForceOnlineRaidInPVE: boolean;
exit_count: number; exit_count: number;
exit_time: number; exit_time: number;
exits: Exit[]; exits: IExit[];
filter_ex: string[]; filter_ex: string[];
limits: ILimit[]; limits: ILimit[];
matching_min_seconds: number; matching_min_seconds: number;
GenerateLocalLootCache: boolean; GenerateLocalLootCache: boolean;
maxItemCountInLocation: MaxItemCountInLocation[]; maxItemCountInLocation: IMaxItemCountInLocation[];
sav_summon_seconds: number; sav_summon_seconds: number;
tmp_location_field_remove_me: number; tmp_location_field_remove_me: number;
transits: ITransit[]; transits: ITransit[];
@ -93,7 +94,7 @@ export interface ILocationBase {
users_spawn_seconds_n: number; users_spawn_seconds_n: number;
users_spawn_seconds_n2: number; users_spawn_seconds_n2: number;
users_summon_seconds: number; users_summon_seconds: number;
waves: Wave[]; waves: IWave[];
} }
export interface ITransit { export interface ITransit {
@ -118,7 +119,7 @@ export interface ILimit extends MinMax {
items: any[]; items: any[];
} }
export interface AirdropParameter { export interface IAirdropParameter {
AirdropPointDeactivateDistance: number; AirdropPointDeactivateDistance: number;
MinPlayersCountToSpawnAirdrop: number; MinPlayersCountToSpawnAirdrop: number;
PlaneAirdropChance: number; PlaneAirdropChance: number;
@ -131,17 +132,17 @@ export interface AirdropParameter {
UnsuccessfulTryPenalty: number; UnsuccessfulTryPenalty: number;
} }
export interface Banner { export interface IBanner {
id: string; id: string;
pic: Pic; pic: IPic;
} }
export interface Pic { export interface IPic {
path: string; path: string;
rcid: string; rcid: string;
} }
export interface BossLocationSpawn { export interface IBossLocationSpawn {
BossChance: number; BossChance: number;
BossDifficult: string; BossDifficult: string;
BossEscortAmount: string; BossEscortAmount: string;
@ -159,18 +160,18 @@ export interface BossLocationSpawn {
DependKarmaPVE?: boolean; DependKarmaPVE?: boolean;
ForceSpawn?: boolean; ForceSpawn?: boolean;
IgnoreMaxBots?: boolean; IgnoreMaxBots?: boolean;
Supports?: BossSupport[]; Supports?: IBossSupport[];
sptId?: string; sptId?: string;
spawnMode: string[]; spawnMode: string[];
} }
export interface BossSupport { export interface IBossSupport {
BossEscortAmount: string; BossEscortAmount: string;
BossEscortDifficult: string[]; BossEscortDifficult: string[];
BossEscortType: string; BossEscortType: string;
} }
export interface BotLocationModifier { export interface IBotLocationModifier {
AccuracySpeed: number; AccuracySpeed: number;
AdditionalHostilitySettings: IAdditionalHostilitySettings[]; AdditionalHostilitySettings: IAdditionalHostilitySettings[];
DistToActivate: number; DistToActivate: number;
@ -208,29 +209,29 @@ export interface IChancedEnemy {
Role: string; Role: string;
} }
export interface MinMaxBot extends MinMax { export interface IMinMaxBot extends MinMax {
WildSpawnType: WildSpawnType | string; WildSpawnType: WildSpawnType | string;
} }
export interface MinPlayerWaitTime { export interface IMinPlayerWaitTime {
minPlayers: number; minPlayers: number;
time: number; time: number;
} }
export interface Preview { export interface IPreview {
path: string; path: string;
rcid: string; rcid: string;
} }
export interface Scene { export interface IScene {
path: string; path: string;
rcid: string; rcid: string;
} }
export interface SpawnPointParam { export interface ISpawnPointParam {
BotZoneName: string; BotZoneName: string;
Categories: string[]; Categories: string[];
ColliderParams: ColliderParams; ColliderParams: IColliderParams;
CorePointId: number; CorePointId: number;
DelayToCanSpawnSec: number; DelayToCanSpawnSec: number;
Id: string; Id: string;
@ -240,17 +241,17 @@ export interface SpawnPointParam {
Sides: string[]; Sides: string[];
} }
export interface ColliderParams { export interface IColliderParams {
_parent: string; _parent: string;
_props: Props; _props: IProps;
} }
export interface Props { export interface IProps {
Center: Ixyz; Center: Ixyz;
Radius: number; Radius: number;
} }
export interface Exit { export interface IExit {
/** % Chance out of 100 exit will appear in raid */ /** % Chance out of 100 exit will appear in raid */
Chance: number; Chance: number;
ChancePVE: number; ChancePVE: number;
@ -275,12 +276,12 @@ export interface Exit {
Side?: string; Side?: string;
} }
export interface MaxItemCountInLocation { export interface IMaxItemCountInLocation {
TemplateId: string; TemplateId: string;
Value: number; Value: number;
} }
export interface Wave { export interface IWave {
BotPreset: string; BotPreset: string;
BotSide: string; BotSide: string;
SpawnPoints: string; SpawnPoints: string;
@ -300,4 +301,6 @@ export enum WildSpawnType {
ASSAULT = "assault", ASSAULT = "assault",
MARKSMAN = "marksman", MARKSMAN = "marksman",
PMCBOT = "pmcbot", PMCBOT = "pmcbot",
BOSSKILLA = "bosskilla",
BOSSKNIGHT = "bossknight",
} }

View File

@ -2,10 +2,10 @@ import { ILocations } from "@spt/models/spt/server/ILocations";
export interface ILocationsGenerateAllResponse { export interface ILocationsGenerateAllResponse {
locations: ILocations; locations: ILocations;
paths: Path[]; paths: IPath[];
} }
export interface Path { export interface IPath {
Source: string; Source: string;
Destination: string; Destination: string;
} }

View File

@ -2,23 +2,23 @@ import { Ixyz } from "@spt/models/eft/common/Ixyz";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
export interface ILooseLoot { export interface ILooseLoot {
spawnpointCount: SpawnpointCount; spawnpointCount: ISpawnpointCount;
spawnpointsForced: SpawnpointsForced[]; spawnpointsForced: ISpawnpointsForced[];
spawnpoints: Spawnpoint[]; spawnpoints: ISpawnpoint[];
} }
export interface SpawnpointCount { export interface ISpawnpointCount {
mean: number; mean: number;
std: number; std: number;
} }
export interface SpawnpointsForced { export interface ISpawnpointsForced {
locationId: string; locationId: string;
probability: number; probability: number;
template: SpawnpointTemplate; template: ISpawnpointTemplate;
} }
export interface SpawnpointTemplate { export interface ISpawnpointTemplate {
Id: string; Id: string;
IsContainer: boolean; IsContainer: boolean;
useGravity: boolean; useGravity: boolean;
@ -27,23 +27,30 @@ export interface SpawnpointTemplate {
Rotation: Ixyz; Rotation: Ixyz;
IsAlwaysSpawn: boolean; IsAlwaysSpawn: boolean;
IsGroupPosition: boolean; IsGroupPosition: boolean;
GroupPositions: any[]; GroupPositions: IGroupPostion[];
Root: string; Root: string;
Items: Item[]; Items: Item[];
} }
export interface Spawnpoint { export interface IGroupPostion {
Name: string;
Weight: number;
Postion: Ixyz;
Rotation: Ixyz;
}
export interface ISpawnpoint {
locationId: string; locationId: string;
probability: number; probability: number;
template: SpawnpointTemplate; template: ISpawnpointTemplate;
itemDistribution: ItemDistribution[]; itemDistribution: ItemDistribution[];
} }
export interface ItemDistribution { export interface ItemDistribution {
composedKey: ComposedKey; composedKey: IComposedKey;
relativeProbability: number; relativeProbability: number;
} }
export interface ComposedKey { export interface IComposedKey {
key: string; key: string;
} }

View File

@ -14,25 +14,25 @@ export interface IBotBase {
sessionId: string; sessionId: string;
savage?: string; savage?: string;
karmaValue: number; karmaValue: number;
Info: Info; Info: IInfo;
Customization: Customization; Customization: ICustomization;
Health: Health; Health: IHealth;
Inventory: Inventory; Inventory: IInventory;
Skills: Skills; Skills: ISkills;
Stats: Stats; Stats: IStats;
Encyclopedia: Record<string, boolean>; Encyclopedia: Record<string, boolean>;
TaskConditionCounters: Record<string, ITaskConditionCounter>; TaskConditionCounters: Record<string, ITaskConditionCounter>;
InsuredItems: IInsuredItem[]; InsuredItems: IInsuredItem[];
Hideout: Hideout; Hideout: IHideout;
Quests: IQuestStatus[]; Quests: IQuestStatus[];
TradersInfo: Record<string, TraderInfo>; TradersInfo: Record<string, ITraderInfo>;
UnlockedInfo: IUnlockedInfo; UnlockedInfo: IUnlockedInfo;
RagfairInfo: RagfairInfo; RagfairInfo: IRagfairInfo;
/** Achievement id and timestamp */ /** Achievement id and timestamp */
Achievements: Record<string, number>; Achievements: Record<string, number>;
RepeatableQuests: IPmcDataRepeatableQuest[]; RepeatableQuests: IPmcDataRepeatableQuest[];
Bonuses: Bonus[]; Bonuses: IBonus[];
Notes: Notes; Notes: INotes;
CarExtractCounts: Record<string, number>; CarExtractCounts: Record<string, number>;
CoopExtractCounts: Record<string, number>; CoopExtractCounts: Record<string, number>;
SurvivorClass: SurvivorClass; SurvivorClass: SurvivorClass;
@ -63,7 +63,7 @@ export interface IUnlockedInfo {
unlockedProductionRecipe: string[]; unlockedProductionRecipe: string[];
} }
export interface Info { export interface IInfo {
EntryPoint: string; EntryPoint: string;
Nickname: string; Nickname: string;
LowerNickname: string; LowerNickname: string;
@ -82,19 +82,19 @@ export interface Info {
lockedMoveCommands: boolean; lockedMoveCommands: boolean;
SavageLockTime: number; SavageLockTime: number;
LastTimePlayedAsSavage: number; LastTimePlayedAsSavage: number;
Settings: Settings; Settings: IBotInfoSettings;
NicknameChangeDate: number; NicknameChangeDate: number;
NeedWipeOptions: any[]; NeedWipeOptions: any[];
lastCompletedWipe: LastCompleted; lastCompletedWipe: ILastCompleted;
Bans: IBan[]; Bans: IBan[];
BannedState: boolean; BannedState: boolean;
BannedUntil: number; BannedUntil: number;
IsStreamerModeAvailable: boolean; IsStreamerModeAvailable: boolean;
lastCompletedEvent?: LastCompleted; lastCompletedEvent?: ILastCompleted;
isMigratedSkills: boolean; isMigratedSkills: boolean;
} }
export interface Settings { export interface IBotInfoSettings {
Role: string; Role: string;
BotDifficulty: string; BotDifficulty: string;
Experience: number; Experience: number;
@ -117,48 +117,48 @@ export enum BanType {
CHANGE_NICKNAME = 6, CHANGE_NICKNAME = 6,
} }
export interface Customization { export interface ICustomization {
Head: string; Head: string;
Body: string; Body: string;
Feet: string; Feet: string;
Hands: string; Hands: string;
} }
export interface Health { export interface IHealth {
Hydration: CurrentMax; Hydration: ICurrentMax;
Energy: CurrentMax; Energy: ICurrentMax;
Temperature: CurrentMax; Temperature: ICurrentMax;
BodyParts: BodyPartsHealth; BodyParts: IBodyPartsHealth;
UpdateTime: number; UpdateTime: number;
Immortal?: boolean; Immortal?: boolean;
} }
export interface BodyPartsHealth { export interface IBodyPartsHealth {
Head: BodyPartHealth; Head: IBodyPartHealth;
Chest: BodyPartHealth; Chest: IBodyPartHealth;
Stomach: BodyPartHealth; Stomach: IBodyPartHealth;
LeftArm: BodyPartHealth; LeftArm: IBodyPartHealth;
RightArm: BodyPartHealth; RightArm: IBodyPartHealth;
LeftLeg: BodyPartHealth; LeftLeg: IBodyPartHealth;
RightLeg: BodyPartHealth; RightLeg: IBodyPartHealth;
} }
export interface BodyPartHealth { export interface IBodyPartHealth {
Health: CurrentMax; Health: ICurrentMax;
Effects?: Record<string, BodyPartEffectProperties>; Effects?: Record<string, IBodyPartEffectProperties>;
} }
export interface BodyPartEffectProperties { export interface IBodyPartEffectProperties {
ExtraData?: any; ExtraData?: any;
Time: number; Time: number;
} }
export interface CurrentMax { export interface ICurrentMax {
Current: number; Current: number;
Maximum: number; Maximum: number;
} }
export interface Inventory { export interface IInventory {
items: Item[]; items: Item[];
equipment: string; equipment: string;
stash: string; stash: string;
@ -173,13 +173,13 @@ export interface Inventory {
export interface IBaseJsonSkills { export interface IBaseJsonSkills {
Common: Record<string, Common>; Common: Record<string, Common>;
Mastering: Record<string, Mastering>; Mastering: Record<string, IMastering>;
Points: number; Points: number;
} }
export interface Skills { export interface ISkills {
Common: Common[]; Common: Common[];
Mastering: Mastering[]; Mastering: IMastering[];
Points: number; Points: number;
} }
@ -195,27 +195,27 @@ export interface Common extends IBaseSkill {
LastAccess?: number; LastAccess?: number;
} }
export interface Mastering extends IBaseSkill {} export interface IMastering extends IBaseSkill {}
export interface Stats { export interface IStats {
Eft?: IEftStats; Eft?: IEftStats;
} }
export interface IEftStats { export interface IEftStats {
CarriedQuestItems: string[]; CarriedQuestItems: string[];
Victims: Victim[]; Victims: IVictim[];
TotalSessionExperience: number; TotalSessionExperience: number;
LastSessionDate: number; LastSessionDate: number;
SessionCounters: SessionCounters; SessionCounters: ISessionCounters;
OverallCounters: OverallCounters; OverallCounters: IOverallCounters;
SessionExperienceMult?: number; SessionExperienceMult?: number;
ExperienceBonusMult?: number; ExperienceBonusMult?: number;
Aggressor?: Aggressor; Aggressor?: IAggressor;
DroppedItems?: IDroppedItem[]; DroppedItems?: IDroppedItem[];
FoundInRaidItems?: FoundInRaidItem[]; FoundInRaidItems?: IFoundInRaidItem[];
DamageHistory?: DamageHistory; DamageHistory?: IDamageHistory;
DeathCause?: DeathCause; DeathCause?: IDeathCause;
LastPlayerState?: LastPlayerState; LastPlayerState?: ILastPlayerState;
TotalInGameTime: number; TotalInGameTime: number;
SurvivorClass?: string; SurvivorClass?: string;
sptLastRaidFenceRepChange?: number; sptLastRaidFenceRepChange?: number;
@ -227,12 +227,12 @@ export interface IDroppedItem {
ZoneId: string; ZoneId: string;
} }
export interface FoundInRaidItem { export interface IFoundInRaidItem {
QuestId: string; QuestId: string;
ItemId: string; ItemId: string;
} }
export interface Victim { export interface IVictim {
AccountId: string; AccountId: string;
ProfileId: string; ProfileId: string;
Name: string; Name: string;
@ -245,20 +245,20 @@ export interface Victim {
Role: string; Role: string;
} }
export interface SessionCounters { export interface ISessionCounters {
Items: CounterKeyValue[]; Items: ICounterKeyValue[];
} }
export interface OverallCounters { export interface IOverallCounters {
Items: CounterKeyValue[]; Items: ICounterKeyValue[];
} }
export interface CounterKeyValue { export interface ICounterKeyValue {
Key: string[]; Key: string[];
Value: number; Value: number;
} }
export interface Aggressor { export interface IAggressor {
AccountId: string; AccountId: string;
ProfileId: string; ProfileId: string;
MainProfileNickname: string; MainProfileNickname: string;
@ -270,13 +270,13 @@ export interface Aggressor {
Category: string; Category: string;
} }
export interface DamageHistory { export interface IDamageHistory {
LethalDamagePart: string; LethalDamagePart: string;
LethalDamage: LethalDamage; LethalDamage: ILethalDamage;
BodyParts: BodyPartsDamageHistory; BodyParts: IBodyPartsDamageHistory;
} }
export interface LethalDamage { export interface ILethalDamage {
Amount: number; Amount: number;
Type: string; Type: string;
SourceId: string; SourceId: string;
@ -285,18 +285,18 @@ export interface LethalDamage {
ImpactsCount: number; ImpactsCount: number;
} }
export interface BodyPartsDamageHistory { export interface IBodyPartsDamageHistory {
Head: DamageStats[]; Head: IDamageStats[];
Chest: DamageStats[]; Chest: IDamageStats[];
Stomach: DamageStats[]; Stomach: IDamageStats[];
LeftArm: DamageStats[]; LeftArm: IDamageStats[];
RightArm: DamageStats[]; RightArm: IDamageStats[];
LeftLeg: DamageStats[]; LeftLeg: IDamageStats[];
RightLeg: DamageStats[]; RightLeg: IDamageStats[];
Common: DamageStats[]; Common: IDamageStats[];
} }
export interface DamageStats { export interface IDamageStats {
Amount: number; Amount: number;
Type: string; Type: string;
SourceId: string; SourceId: string;
@ -305,27 +305,27 @@ export interface DamageStats {
ImpactsCount: number; ImpactsCount: number;
} }
export interface DeathCause { export interface IDeathCause {
DamageType: string; DamageType: string;
Side: string; Side: string;
Role: string; Role: string;
WeaponId: string; WeaponId: string;
} }
export interface LastPlayerState { export interface ILastPlayerState {
Info: LastPlayerStateInfo; Info: ILastPlayerStateInfo;
Customization: Record<string, string>; Customization: Record<string, string>;
Equipment: any; Equipment: any;
} }
export interface LastPlayerStateInfo { export interface ILastPlayerStateInfo {
Nickname: string; Nickname: string;
Side: string; Side: string;
Level: number; Level: number;
MemberCategory: MemberCategory; MemberCategory: MemberCategory;
} }
export interface BackendCounter { export interface IBackendCounter {
id: string; id: string;
qid?: string; qid?: string;
value: number; value: number;
@ -337,9 +337,9 @@ export interface IInsuredItem {
itemId: string; itemId: string;
} }
export interface Hideout { export interface IHideout {
Production: Record<string, Productive>; Production: Record<string, IProductive>;
Areas: HideoutArea[]; Areas: IBotHideoutArea[];
Improvements: Record<string, IHideoutImprovement>; Improvements: Record<string, IHideoutImprovement>;
HideoutCounters: IHideoutCounters; HideoutCounters: IHideoutCounters;
Seed: number; Seed: number;
@ -359,8 +359,8 @@ export interface IHideoutImprovement {
improveCompleteTimestamp: number; improveCompleteTimestamp: number;
} }
export interface Productive { export interface IProductive {
Products: Product[]; Products: IProduct[];
/** Seconds passed of production */ /** Seconds passed of production */
Progress?: number; Progress?: number;
/** Is craft in some state of being worked on by client (crafting/ready to pick up) */ /** Is craft in some state of being worked on by client (crafting/ready to pick up) */
@ -389,23 +389,23 @@ export interface Productive {
sptIsCultistCircle?: boolean; sptIsCultistCircle?: boolean;
} }
export interface Production extends Productive { export interface IProduction extends IProductive {
RecipeId: string; RecipeId: string;
SkipTime: number; SkipTime: number;
ProductionTime: number; ProductionTime: number;
} }
export interface ScavCase extends Productive { export interface IScavCase extends IProductive {
RecipeId: string; RecipeId: string;
} }
export interface Product { export interface IProduct {
_id: string; _id: string;
_tpl: string; _tpl: string;
upd?: Upd; upd?: Upd;
} }
export interface HideoutArea { export interface IBotHideoutArea {
type: HideoutAreas; type: HideoutAreas;
level: number; level: number;
active: boolean; active: boolean;
@ -413,28 +413,28 @@ export interface HideoutArea {
/** Must be integer */ /** Must be integer */
completeTime: number; completeTime: number;
constructing: boolean; constructing: boolean;
slots: HideoutSlot[]; slots: IHideoutSlot[];
lastRecipe: string; lastRecipe: string;
} }
export interface HideoutSlot { export interface IHideoutSlot {
/** SPT specific value to keep track of what index this slot is (0,1,2,3 etc) */ /** SPT specific value to keep track of what index this slot is (0,1,2,3 etc) */
locationIndex: number; locationIndex: number;
item?: HideoutItem[]; item?: IHideoutItem[];
} }
export interface HideoutItem { export interface IHideoutItem {
_id: string; _id: string;
_tpl: string; _tpl: string;
upd?: Upd; upd?: Upd;
} }
export interface LastCompleted { export interface ILastCompleted {
$oid: string; $oid: string;
} }
export interface Notes { export interface INotes {
Notes: Note[]; Notes: INote[];
} }
export type CarExtractCounts = {}; export type CarExtractCounts = {};
@ -457,7 +457,7 @@ export interface IQuestStatus {
availableAfter?: number; availableAfter?: number;
} }
export interface TraderInfo { export interface ITraderInfo {
loyaltyLevel?: number; loyaltyLevel?: number;
salesSum: number; salesSum: number;
standing: number; standing: number;
@ -466,13 +466,13 @@ export interface TraderInfo {
disabled: boolean; disabled: boolean;
} }
export interface RagfairInfo { export interface IRagfairInfo {
rating: number; rating: number;
isRatingGrowing: boolean; isRatingGrowing: boolean;
offers: IRagfairOffer[]; offers: IRagfairOffer[];
} }
export interface Bonus { export interface IBonus {
id?: string; id?: string;
type: BonusType; type: BonusType;
templateId?: string; templateId?: string;
@ -485,7 +485,7 @@ export interface Bonus {
skillType?: BonusSkillType; skillType?: BonusSkillType;
} }
export interface Note { export interface INote {
Time: number; Time: number;
Text: string; Text: string;
} }

View File

@ -1,5 +1,5 @@
import { MinMax } from "@spt/models/common/MinMax"; import { MinMax } from "@spt/models/common/MinMax";
import { Skills } from "@spt/models/eft/common/tables/IBotBase"; import { ISkills } from "@spt/models/eft/common/tables/IBotBase";
export interface IBotType { export interface IBotType {
appearance: Appearance; appearance: Appearance;
@ -11,7 +11,7 @@ export interface IBotType {
health: Health; health: Health;
inventory: Inventory; inventory: Inventory;
lastName: string[]; lastName: string[];
skills: Skills; skills: ISkills;
} }
export interface Appearance { export interface Appearance {

View File

@ -1,4 +1,10 @@
import { Health, IMoneyTransferLimits, IQuestStatus, Productive, Skills } from "@spt/models/eft/common/tables/IBotBase"; import {
IHealth,
IMoneyTransferLimits,
IProductive,
IQuestStatus,
ISkills,
} from "@spt/models/eft/common/tables/IBotBase";
import { Item, Upd } from "@spt/models/eft/common/tables/IItem"; import { Item, Upd } from "@spt/models/eft/common/tables/IItem";
import { IQuest } from "@spt/models/eft/common/tables/IQuest"; import { IQuest } from "@spt/models/eft/common/tables/IQuest";
import { IPmcDataRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests"; import { IPmcDataRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests";
@ -27,11 +33,11 @@ export interface ProfileChange {
weaponBuilds: IWeaponBuildChange[]; weaponBuilds: IWeaponBuildChange[];
equipmentBuilds: IEquipmentBuildChange[]; equipmentBuilds: IEquipmentBuildChange[];
items: ItemChanges; items: ItemChanges;
production: Record<string, Productive>; production: Record<string, IProductive>;
/** Hideout area improvement id */ /** Hideout area improvement id */
improvements: Record<string, Improvement>; improvements: Record<string, Improvement>;
skills: Skills; skills: ISkills;
health: Health; health: IHealth;
traderRelations: Record<string, TraderData>; traderRelations: Record<string, TraderData>;
moneyTransferLimitData: IMoneyTransferLimits; moneyTransferLimitData: IMoneyTransferLimits;
repeatableQuests?: IPmcDataRepeatableQuest[]; repeatableQuests?: IPmcDataRepeatableQuest[];

View File

@ -1,4 +1,4 @@
import { Skills } from "@spt/models/eft/common/tables/IBotBase"; import { ISkills } from "@spt/models/eft/common/tables/IBotBase";
export interface IPlayerIncrementSkillLevelRequestData { export interface IPlayerIncrementSkillLevelRequestData {
_id: string; _id: string;
@ -8,7 +8,7 @@ export interface IPlayerIncrementSkillLevelRequestData {
builds: any[]; builds: any[];
items: Items; items: Items;
production: Production; production: Production;
skills: Skills; skills: ISkills;
traderRelations: TraderRelations; traderRelations: TraderRelations;
} }

View File

@ -1,4 +1,4 @@
import { OverallCounters, Skills } from "@spt/models/eft/common/tables/IBotBase"; import { IOverallCounters, ISkills } from "@spt/models/eft/common/tables/IBotBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
export interface IGetOtherProfileResponse { export interface IGetOtherProfileResponse {
@ -6,7 +6,7 @@ export interface IGetOtherProfileResponse {
aid: number; aid: number;
info: IOtherProfileInfo; info: IOtherProfileInfo;
customization: IOtherProfileCustomization; customization: IOtherProfileCustomization;
skills: Skills; skills: ISkills;
equipment: IOtherProfileEquipment; equipment: IOtherProfileEquipment;
achievements: Record<string, number>; achievements: Record<string, number>;
favoriteItems: Item[]; favoriteItems: Item[];
@ -42,5 +42,5 @@ export interface IOtherProfileStats {
export interface IOtherProfileSubStats { export interface IOtherProfileSubStats {
totalInGameTime: number; totalInGameTime: number;
overAllCounters: OverallCounters; overAllCounters: IOverallCounters;
} }

View File

@ -1,4 +1,4 @@
import { Inventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase";
import { Chances, Mods } from "@spt/models/eft/common/tables/IBotType"; import { Chances, Mods } from "@spt/models/eft/common/tables/IBotType";
import { EquipmentFilters, RandomisationDetails } from "@spt/models/spt/config/IBotConfig"; import { EquipmentFilters, RandomisationDetails } from "@spt/models/spt/config/IBotConfig";

View File

@ -1,5 +1,5 @@
import { MinMax } from "@spt/models/common/MinMax"; import { MinMax } from "@spt/models/common/MinMax";
import { BossLocationSpawn, Wave } from "@spt/models/eft/common/ILocationBase"; import { IBossLocationSpawn, IWave } from "@spt/models/eft/common/ILocationBase";
import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig"; import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig";
export interface ILocationConfig extends IBaseConfig { export interface ILocationConfig extends IBaseConfig {
@ -10,10 +10,10 @@ export interface ILocationConfig extends IBaseConfig {
rogueLighthouseSpawnTimeSettings: IRogueLighthouseSpawnTimeSettings; rogueLighthouseSpawnTimeSettings: IRogueLighthouseSpawnTimeSettings;
/** When a map has hit max alive bots, any wave that should spawn will be reduced to 1 bot in size and placed in a spawn queue, this splits waves into smaller sizes to reduce the impact of this behaviour */ /** When a map has hit max alive bots, any wave that should spawn will be reduced to 1 bot in size and placed in a spawn queue, this splits waves into smaller sizes to reduce the impact of this behaviour */
splitWaveIntoSingleSpawnsSettings: ISplitWaveSettings; splitWaveIntoSingleSpawnsSettings: ISplitWaveSettings;
looseLootMultiplier: LootMultiplier; looseLootMultiplier: ILootMultiplier;
staticLootMultiplier: LootMultiplier; staticLootMultiplier: ILootMultiplier;
/** Custom bot waves to add to a locations base json on game start if addCustomBotWavesToMaps is true */ /** Custom bot waves to add to a locations base json on game start if addCustomBotWavesToMaps is true */
customWaves: CustomWaves; customWaves: ICustomWaves;
/** Open zones to add to map */ /** Open zones to add to map */
openZones: Record<string, string[]>; openZones: Record<string, string[]>;
/** Key = map id, value = item tpls that should only have one forced loot spawn position */ /** Key = map id, value = item tpls that should only have one forced loot spawn position */
@ -68,10 +68,10 @@ export interface ISplitWaveSettings {
waveSizeThreshold: number; waveSizeThreshold: number;
} }
export interface CustomWaves { export interface ICustomWaves {
/** Bosses spawn on raid start */ /** Bosses spawn on raid start */
boss: Record<string, BossLocationSpawn[]>; boss: Record<string, IBossLocationSpawn[]>;
normal: Record<string, Wave[]>; normal: Record<string, IWave[]>;
} }
export interface IBotTypeLimit extends MinMax { export interface IBotTypeLimit extends MinMax {
@ -79,7 +79,7 @@ export interface IBotTypeLimit extends MinMax {
} }
/** Multiplier to apply to the loot count for a given map */ /** Multiplier to apply to the loot count for a given map */
export interface LootMultiplier { export interface ILootMultiplier {
bigmap: number; bigmap: number;
develop: number; develop: number;
factory4_day: number; factory4_day: number;

View File

@ -1,10 +1,10 @@
import { Spawnpoint } from "@spt/models/eft/common/ILooseLoot"; import { ISpawnpoint } from "@spt/models/eft/common/ILooseLoot";
import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig"; import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig";
export interface ILootConfig extends IBaseConfig { export interface ILootConfig extends IBaseConfig {
kind: "spt-loot"; kind: "spt-loot";
/** Spawn positions to add into a map, key=mapid */ /** Spawn positions to add into a map, key=mapid */
looseLoot: Record<string, Spawnpoint[]>; looseLoot: Record<string, ISpawnpoint[]>;
/** Loose loot probability adjustments to apply on game start */ /** Loose loot probability adjustments to apply on game start */
looseLootSpawnPointAdjustments: Record<string, Record<string, number>>; looseLootSpawnPointAdjustments: Record<string, Record<string, number>>;
} }

View File

@ -1,4 +1,4 @@
import { BossLocationSpawn } from "@spt/models/eft/common/ILocationBase"; import { IBossLocationSpawn } from "@spt/models/eft/common/ILocationBase";
import { SeasonalEventType } from "@spt/models/enums/SeasonalEventType"; import { SeasonalEventType } from "@spt/models/enums/SeasonalEventType";
import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig"; import { IBaseConfig } from "@spt/models/spt/config/IBaseConfig";
@ -9,7 +9,7 @@ export interface ISeasonalEventConfig extends IBaseConfig {
eventGear: Record<string, Record<string, Record<string, Record<string, number>>>>; eventGear: Record<string, Record<string, Record<string, Record<string, number>>>>;
events: ISeasonalEvent[]; events: ISeasonalEvent[];
eventBotMapping: Record<string, string>; eventBotMapping: Record<string, string>;
eventBossSpawns: Record<string, Record<string, BossLocationSpawn[]>>; eventBossSpawns: Record<string, Record<string, IBossLocationSpawn[]>>;
gifterSettings: GifterSetting[]; gifterSettings: GifterSetting[];
} }

View File

@ -1,4 +1,4 @@
import { Inventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase"; import { IInventory as PmcInventory } from "@spt/models/eft/common/tables/IBotBase";
import { Chances, Generation, Inventory } from "@spt/models/eft/common/tables/IBotType"; import { Chances, Generation, Inventory } from "@spt/models/eft/common/tables/IBotType";
export interface IBotGenerator { export interface IBotGenerator {

View File

@ -4,7 +4,7 @@ import {
IStaticForcedProps, IStaticForcedProps,
IStaticLootDetails, IStaticLootDetails,
} from "@spt/models/eft/common/ILocation"; } from "@spt/models/eft/common/ILocation";
import { ILooseLoot, SpawnpointTemplate } from "@spt/models/eft/common/ILooseLoot"; import { ILooseLoot, ISpawnpointTemplate } from "@spt/models/eft/common/ILooseLoot";
export interface ILocationGenerator { export interface ILocationGenerator {
generateContainerLoot( generateContainerLoot(
@ -18,5 +18,5 @@ export interface ILocationGenerator {
dynamicLootDist: ILooseLoot, dynamicLootDist: ILooseLoot,
staticAmmoDist: Record<string, IStaticAmmoDetails[]>, staticAmmoDist: Record<string, IStaticAmmoDetails[]>,
locationName: string, locationName: string,
): SpawnpointTemplate[]; ): ISpawnpointTemplate[];
} }

View File

@ -3,8 +3,8 @@ import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { import {
IHideoutImprovement, IHideoutImprovement,
IMoneyTransferLimits, IMoneyTransferLimits,
Productive, IProductive,
TraderInfo, ITraderInfo,
} from "@spt/models/eft/common/tables/IBotBase"; } from "@spt/models/eft/common/tables/IBotBase";
import { ProfileChange, TraderData } from "@spt/models/eft/itemEvent/IItemEventRouterBase"; import { ProfileChange, TraderData } from "@spt/models/eft/itemEvent/IItemEventRouterBase";
import { IItemEventRouterResponse } from "@spt/models/eft/itemEvent/IItemEventRouterResponse"; import { IItemEventRouterResponse } from "@spt/models/eft/itemEvent/IItemEventRouterResponse";
@ -103,7 +103,7 @@ export class EventOutputHolder {
* @param traderData server data for traders * @param traderData server data for traders
* @returns dict of trader id + TraderData * @returns dict of trader id + TraderData
*/ */
protected constructTraderRelations(traderData: Record<string, TraderInfo>): Record<string, TraderData> { protected constructTraderRelations(traderData: Record<string, ITraderInfo>): Record<string, TraderData> {
const result: Record<string, TraderData> = {}; const result: Record<string, TraderData> = {};
for (const traderId in traderData) { for (const traderId in traderData) {
@ -148,9 +148,9 @@ export class EventOutputHolder {
* @returns dictionary of hideout productions * @returns dictionary of hideout productions
*/ */
protected getProductionsFromProfileAndFlagComplete( protected getProductionsFromProfileAndFlagComplete(
productions: Record<string, Productive>, productions: Record<string, IProductive>,
sessionId: string, sessionId: string,
): Record<string, Productive> | undefined { ): Record<string, IProductive> | undefined {
for (const productionKey in productions) { for (const productionKey in productions) {
const production = productions[productionKey]; const production = productions[productionKey];
if (!production) { if (!production) {
@ -196,7 +196,7 @@ export class EventOutputHolder {
* Required as continuous productions don't reset and stay at 100% completion but client thinks it hasn't started * Required as continuous productions don't reset and stay at 100% completion but client thinks it hasn't started
* @param productions Productions in a profile * @param productions Productions in a profile
*/ */
protected cleanUpCompleteCraftsInProfile(productions: Record<string, Productive>): void { protected cleanUpCompleteCraftsInProfile(productions: Record<string, IProductive>): void {
for (const productionKey in productions) { for (const productionKey in productions) {
const production = productions[productionKey]; const production = productions[productionKey];
if (production?.sptIsComplete && production?.sptIsContinuous) { if (production?.sptIsComplete && production?.sptIsContinuous) {

View File

@ -4,7 +4,7 @@ import { ItemHelper } from "@spt/helpers/ItemHelper";
import { PresetHelper } from "@spt/helpers/PresetHelper"; import { PresetHelper } from "@spt/helpers/PresetHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { HideoutArea } from "@spt/models/eft/common/tables/IBotBase"; import { IBotHideoutArea } from "@spt/models/eft/common/tables/IBotBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { IStageRequirement } from "@spt/models/eft/hideout/IHideoutArea"; import { IStageRequirement } from "@spt/models/eft/hideout/IHideoutArea";
import { IHideoutCircleOfCultistProductionStartRequestData } from "@spt/models/eft/hideout/IHideoutCircleOfCultistProductionStartRequestData"; import { IHideoutCircleOfCultistProductionStartRequestData } from "@spt/models/eft/hideout/IHideoutCircleOfCultistProductionStartRequestData";
@ -538,7 +538,7 @@ export class CircleOfCultistService {
* @param areas Hideout areas to iterate over * @param areas Hideout areas to iterate over
* @returns Active area array * @returns Active area array
*/ */
protected getPlayerAccessibleHideoutAreas(areas: HideoutArea[]): HideoutArea[] { protected getPlayerAccessibleHideoutAreas(areas: IBotHideoutArea[]): IBotHideoutArea[] {
return areas.filter((area) => { return areas.filter((area) => {
if (area.type === HideoutAreas.CHRISTMAS_TREE && !this.seasonalEventService.christmasEventEnabled()) { if (area.type === HideoutAreas.CHRISTMAS_TREE && !this.seasonalEventService.christmasEventEnabled()) {
// Christmas tree area and not Christmas, skip // Christmas tree area and not Christmas, skip

View File

@ -1,4 +1,4 @@
import { BossLocationSpawn, Wave } from "@spt/models/eft/common/ILocationBase"; import { IBossLocationSpawn, IWave } from "@spt/models/eft/common/ILocationBase";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { ILocationConfig } from "@spt/models/spt/config/ILocationConfig"; import { ILocationConfig } from "@spt/models/spt/config/ILocationConfig";
import { ILogger } from "@spt/models/spt/utils/ILogger"; import { ILogger } from "@spt/models/spt/utils/ILogger";
@ -25,7 +25,7 @@ export class CustomLocationWaveService {
* @param locationId e.g. factory4_day, bigmap * @param locationId e.g. factory4_day, bigmap
* @param waveToAdd Boss wave to add to map * @param waveToAdd Boss wave to add to map
*/ */
public addBossWaveToMap(locationId: string, waveToAdd: BossLocationSpawn): void { public addBossWaveToMap(locationId: string, waveToAdd: IBossLocationSpawn): void {
this.locationConfig.customWaves.boss[locationId].push(waveToAdd); this.locationConfig.customWaves.boss[locationId].push(waveToAdd);
} }
@ -34,7 +34,7 @@ export class CustomLocationWaveService {
* @param locationId e.g. factory4_day, bigmap * @param locationId e.g. factory4_day, bigmap
* @param waveToAdd Wave to add to map * @param waveToAdd Wave to add to map
*/ */
public addNormalWaveToMap(locationId: string, waveToAdd: Wave): void { public addNormalWaveToMap(locationId: string, waveToAdd: IWave): void {
this.locationConfig.customWaves.normal[locationId].push(waveToAdd); this.locationConfig.customWaves.normal[locationId].push(waveToAdd);
} }

View File

@ -9,7 +9,7 @@ import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { TraderHelper } from "@spt/helpers/TraderHelper"; import { TraderHelper } from "@spt/helpers/TraderHelper";
import { ILocationBase } from "@spt/models/eft/common/ILocationBase"; import { ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { Common, IQuestStatus, TraderInfo } from "@spt/models/eft/common/tables/IBotBase"; import { Common, IQuestStatus, ITraderInfo } from "@spt/models/eft/common/tables/IBotBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { IEndLocalRaidRequestData, IEndRaidResult } from "@spt/models/eft/match/IEndLocalRaidRequestData"; import { IEndLocalRaidRequestData, IEndRaidResult } from "@spt/models/eft/match/IEndLocalRaidRequestData";
import { IStartLocalRaidRequestData } from "@spt/models/eft/match/IStartLocalRaidRequestData"; import { IStartLocalRaidRequestData } from "@spt/models/eft/match/IStartLocalRaidRequestData";
@ -661,8 +661,8 @@ export class LocationLifecycleService {
* @param tradersClientProfile Client * @param tradersClientProfile Client
*/ */
protected applyTraderStandingAdjustments( protected applyTraderStandingAdjustments(
tradersServerProfile: Record<string, TraderInfo>, tradersServerProfile: Record<string, ITraderInfo>,
tradersClientProfile: Record<string, TraderInfo>, tradersClientProfile: Record<string, ITraderInfo>,
): void { ): void {
for (const traderId in tradersClientProfile) { for (const traderId in tradersClientProfile) {
const serverProfileTrader = tradersServerProfile[traderId]; const serverProfileTrader = tradersServerProfile[traderId];

View File

@ -1,7 +1,7 @@
import { NotificationSendHelper } from "@spt/helpers/NotificationSendHelper"; import { NotificationSendHelper } from "@spt/helpers/NotificationSendHelper";
import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper"; import { WeightedRandomHelper } from "@spt/helpers/WeightedRandomHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { Aggressor, Victim } from "@spt/models/eft/common/tables/IBotBase"; import { IAggressor, IVictim } from "@spt/models/eft/common/tables/IBotBase";
import { IUserDialogInfo } from "@spt/models/eft/profile/ISptProfile"; import { IUserDialogInfo } from "@spt/models/eft/profile/ISptProfile";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { MemberCategory } from "@spt/models/enums/MemberCategory"; import { MemberCategory } from "@spt/models/enums/MemberCategory";
@ -43,7 +43,7 @@ export class PmcChatResponseService {
* @param pmcVictims Array of bots killed by player * @param pmcVictims Array of bots killed by player
* @param pmcData Player profile * @param pmcData Player profile
*/ */
public sendVictimResponse(sessionId: string, pmcVictims: Victim[], pmcData: IPmcData): void { public sendVictimResponse(sessionId: string, pmcVictims: IVictim[], pmcData: IPmcData): void {
for (const victim of pmcVictims) { for (const victim of pmcVictims) {
if (!this.randomUtil.getChance100(this.pmcResponsesConfig.victim.responseChancePercent)) { if (!this.randomUtil.getChance100(this.pmcResponsesConfig.victim.responseChancePercent)) {
continue; continue;
@ -68,7 +68,7 @@ export class PmcChatResponseService {
* @param pmcData Players profile * @param pmcData Players profile
* @param killer The bot who killed the player * @param killer The bot who killed the player
*/ */
public sendKillerResponse(sessionId: string, pmcData: IPmcData, killer: Aggressor): void { public sendKillerResponse(sessionId: string, pmcData: IPmcData, killer: IAggressor): void {
if (!killer) { if (!killer) {
return; return;
} }
@ -240,7 +240,7 @@ export class PmcChatResponseService {
* @param pmcVictims Possible victims to choose from * @param pmcVictims Possible victims to choose from
* @returns IUserDialogInfo * @returns IUserDialogInfo
*/ */
protected chooseRandomVictim(pmcVictims: Victim[]): IUserDialogInfo { protected chooseRandomVictim(pmcVictims: IVictim[]): IUserDialogInfo {
const randomVictim = this.randomUtil.getArrayValue(pmcVictims); const randomVictim = this.randomUtil.getArrayValue(pmcVictims);
return this.getVictimDetails(randomVictim); return this.getVictimDetails(randomVictim);
@ -251,7 +251,7 @@ export class PmcChatResponseService {
* @param pmcVictim victim to convert * @param pmcVictim victim to convert
* @returns IUserDialogInfo * @returns IUserDialogInfo
*/ */
protected getVictimDetails(pmcVictim: Victim): IUserDialogInfo { protected getVictimDetails(pmcVictim: IVictim): IUserDialogInfo {
const categories = [ const categories = [
MemberCategory.UNIQUE_ID, MemberCategory.UNIQUE_ID,
MemberCategory.DEFAULT, MemberCategory.DEFAULT,

View File

@ -4,7 +4,7 @@ import { ItemHelper } from "@spt/helpers/ItemHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { TraderHelper } from "@spt/helpers/TraderHelper"; import { TraderHelper } from "@spt/helpers/TraderHelper";
import { IPmcData } from "@spt/models/eft/common/IPmcData"; import { IPmcData } from "@spt/models/eft/common/IPmcData";
import { Bonus, HideoutSlot } from "@spt/models/eft/common/tables/IBotBase"; import { IBonus, IHideoutSlot } from "@spt/models/eft/common/tables/IBotBase";
import { IPmcDataRepeatableQuest, IRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests"; import { IPmcDataRepeatableQuest, IRepeatableQuest } from "@spt/models/eft/common/tables/IRepeatableQuests";
import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem";
import { StageBonus } from "@spt/models/eft/hideout/IHideoutArea"; import { StageBonus } from "@spt/models/eft/hideout/IHideoutArea";
@ -328,7 +328,7 @@ export class ProfileFixerService {
area.slots = this.addObjectsToArray(emptyItemCount, area.slots); area.slots = this.addObjectsToArray(emptyItemCount, area.slots);
} }
protected addObjectsToArray(count: number, slots: HideoutSlot[]): HideoutSlot[] { protected addObjectsToArray(count: number, slots: IHideoutSlot[]): IHideoutSlot[] {
for (let i = 0; i < count; i++) { for (let i = 0; i < count; i++) {
if (!slots.some((x) => x.locationIndex === i)) { if (!slots.some((x) => x.locationIndex === i)) {
slots.push({ locationIndex: i }); slots.push({ locationIndex: i });
@ -632,7 +632,7 @@ export class ProfileFixerService {
* @param bonus bonus to find * @param bonus bonus to find
* @returns matching bonus * @returns matching bonus
*/ */
protected getBonusFromProfile(profileBonuses: Bonus[], bonus: StageBonus): Bonus | undefined { protected getBonusFromProfile(profileBonuses: IBonus[], bonus: StageBonus): IBonus | undefined {
// match by id first, used by "TextBonus" bonuses // match by id first, used by "TextBonus" bonuses
if (bonus.id) { if (bonus.id) {
return profileBonuses.find((x) => x.id === bonus.id); return profileBonuses.find((x) => x.id === bonus.id);

View File

@ -5,7 +5,11 @@ import { ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { IGetRaidTimeRequest } from "@spt/models/eft/game/IGetRaidTimeRequest"; import { IGetRaidTimeRequest } from "@spt/models/eft/game/IGetRaidTimeRequest";
import { ExtractChange, IGetRaidTimeResponse } from "@spt/models/eft/game/IGetRaidTimeResponse"; import { ExtractChange, IGetRaidTimeResponse } from "@spt/models/eft/game/IGetRaidTimeResponse";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { ILocationConfig, IScavRaidTimeLocationSettings, LootMultiplier } from "@spt/models/spt/config/ILocationConfig"; import {
ILocationConfig,
ILootMultiplier,
IScavRaidTimeLocationSettings,
} from "@spt/models/spt/config/ILocationConfig";
import { IRaidChanges } from "@spt/models/spt/location/IRaidChanges"; import { IRaidChanges } from "@spt/models/spt/location/IRaidChanges";
import { ILogger } from "@spt/models/spt/utils/ILogger"; import { ILogger } from "@spt/models/spt/utils/ILogger";
import { ConfigServer } from "@spt/servers/ConfigServer"; import { ConfigServer } from "@spt/servers/ConfigServer";
@ -55,7 +59,7 @@ export class RaidTimeAdjustmentService {
* @param mapLootMultiplers Multiplers to adjust * @param mapLootMultiplers Multiplers to adjust
* @param loosePercent Percent to change values to * @param loosePercent Percent to change values to
*/ */
protected adjustLootMultipliers(mapLootMultiplers: LootMultiplier, loosePercent: number): void { protected adjustLootMultipliers(mapLootMultiplers: ILootMultiplier, loosePercent: number): void {
for (const key in mapLootMultiplers) { for (const key in mapLootMultiplers) {
mapLootMultiplers[key] = this.randomUtil.getPercentOfValue(mapLootMultiplers[key], loosePercent); mapLootMultiplers[key] = this.randomUtil.getPercentOfValue(mapLootMultiplers[key], loosePercent);
} }

View File

@ -2,7 +2,7 @@ import { BotHelper } from "@spt/helpers/BotHelper";
import { ProfileHelper } from "@spt/helpers/ProfileHelper"; import { ProfileHelper } from "@spt/helpers/ProfileHelper";
import { IConfig } from "@spt/models/eft/common/IGlobals"; import { IConfig } from "@spt/models/eft/common/IGlobals";
import { ILocation } from "@spt/models/eft/common/ILocation"; import { ILocation } from "@spt/models/eft/common/ILocation";
import { BossLocationSpawn } from "@spt/models/eft/common/ILocationBase"; import { IBossLocationSpawn } from "@spt/models/eft/common/ILocationBase";
import { Inventory } from "@spt/models/eft/common/tables/IBotType"; import { Inventory } from "@spt/models/eft/common/tables/IBotType";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { ItemTpl } from "@spt/models/enums/ItemTpl"; import { ItemTpl } from "@spt/models/enums/ItemTpl";
@ -390,7 +390,7 @@ export class SeasonalEventService {
for (const boss of bossesToAdd) { for (const boss of bossesToAdd) {
const locations = this.databaseService.getLocations(); const locations = this.databaseService.getLocations();
const mapBosses: BossLocationSpawn[] = locations[mapKey].base.BossLocationSpawn; const mapBosses: IBossLocationSpawn[] = locations[mapKey].base.BossLocationSpawn;
if (!mapBosses.some((bossSpawn) => bossSpawn.BossName === boss.BossName)) { if (!mapBosses.some((bossSpawn) => bossSpawn.BossName === boss.BossName)) {
locations[mapKey].base.BossLocationSpawn.push(...bossesToAdd); locations[mapKey].base.BossLocationSpawn.push(...bossesToAdd);
} }