From 3d4447c978b72299873ed1e3599a61c08d1d24d7 Mon Sep 17 00:00:00 2001 From: Dev Date: Tue, 28 May 2024 11:11:50 +0100 Subject: [PATCH] Added `ITemplates` interface --- .../src/models/spt/server/IDatabaseTables.ts | 30 ++----------------- .../src/models/spt/templates/ITemplates.ts | 30 +++++++++++++++++++ 2 files changed, 32 insertions(+), 28 deletions(-) create mode 100644 project/src/models/spt/templates/ITemplates.ts diff --git a/project/src/models/spt/server/IDatabaseTables.ts b/project/src/models/spt/server/IDatabaseTables.ts index ec506db8..be74a701 100644 --- a/project/src/models/spt/server/IDatabaseTables.ts +++ b/project/src/models/spt/server/IDatabaseTables.ts @@ -1,20 +1,13 @@ import { IGlobals } from "@spt/models/eft/common/IGlobals"; -import { IAchievement } from "@spt/models/eft/common/tables/IAchievement"; -import { ICustomizationItem } from "@spt/models/eft/common/tables/ICustomizationItem"; -import { IHandbookBase } from "@spt/models/eft/common/tables/IHandbookBase"; import { IMatch } from "@spt/models/eft/common/tables/IMatch"; -import { IProfileTemplates } from "@spt/models/eft/common/tables/IProfileTemplate"; -import { IQuest } from "@spt/models/eft/common/tables/IQuest"; -import { IRepeatableQuestDatabase } from "@spt/models/eft/common/tables/IRepeatableQuests"; -import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; import { ITrader } from "@spt/models/eft/common/tables/ITrader"; -import { IDefaultEquipmentPreset } from "@spt/models/eft/profile/ISptProfile"; import { IBots } from "@spt/models/spt/bots/IBots"; import { IHideout } from "@spt/models/spt/hideout/IHideout"; import { ILocaleBase } from "@spt/models/spt/server/ILocaleBase"; import { ILocations } from "@spt/models/spt/server/ILocations"; import { IServerBase } from "@spt/models/spt/server/IServerBase"; import { ISettingsBase } from "@spt/models/spt/server/ISettingsBase"; +import { ITemplates } from "@spt/models/spt/templates/ITemplates"; export interface IDatabaseTables { @@ -23,26 +16,7 @@ export interface IDatabaseTables locales?: ILocaleBase locations?: ILocations match?: IMatch - templates?: { - character: string[] - items: Record - quests: Record - repeatableQuests: IRepeatableQuestDatabase - handbook: IHandbookBase - customization: Record - - /** The profile templates listed in the launcher on profile creation, split by account type (e.g. Standard) then side (e.g. bear/usec) */ - profiles: IProfileTemplates - - /** Flea prices of items - gathered from online flea market dump */ - prices: Record - - /** Default equipment loadouts that show on main inventory screen */ - defaultEquipmentPresets: IDefaultEquipmentPreset[] - - /** Achievements */ - achievements: IAchievement[] - } + templates?: ITemplates traders?: Record globals?: IGlobals diff --git a/project/src/models/spt/templates/ITemplates.ts b/project/src/models/spt/templates/ITemplates.ts new file mode 100644 index 00000000..023f2751 --- /dev/null +++ b/project/src/models/spt/templates/ITemplates.ts @@ -0,0 +1,30 @@ +import { IAchievement } from "@spt/models/eft/common/tables/IAchievement"; +import { ICustomizationItem } from "@spt/models/eft/common/tables/ICustomizationItem"; +import { IHandbookBase } from "@spt/models/eft/common/tables/IHandbookBase"; +import { IProfileTemplates } from "@spt/models/eft/common/tables/IProfileTemplate"; +import { IQuest } from "@spt/models/eft/common/tables/IQuest"; +import { IRepeatableQuestDatabase } from "@spt/models/eft/common/tables/IRepeatableQuests"; +import { ITemplateItem } from "@spt/models/eft/common/tables/ITemplateItem"; +import { IDefaultEquipmentPreset } from "@spt/models/eft/profile/ISptProfile"; + +export interface ITemplates +{ + character: string[] + items: Record + quests: Record + repeatableQuests: IRepeatableQuestDatabase + handbook: IHandbookBase + customization: Record + + /** The profile templates listed in the launcher on profile creation, split by account type (e.g. Standard) then side (e.g. bear/usec) */ + profiles: IProfileTemplates + + /** Flea prices of items - gathered from online flea market dump */ + prices: Record + + /** Default equipment loadouts that show on main inventory screen */ + defaultEquipmentPresets: IDefaultEquipmentPreset[] + + /** Achievements */ + achievements: IAchievement[] +}