Renamed IHandbookBase interfaces

This commit is contained in:
Dev 2024-09-01 13:18:30 +01:00
parent 955416f5be
commit 02b903e13e
3 changed files with 8 additions and 8 deletions

View File

@ -1,4 +1,4 @@
import { Category } from "@spt/models/eft/common/tables/IHandbookBase"; import { IHandbookCategory } from "@spt/models/eft/common/tables/IHandbookBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { Money } from "@spt/models/enums/Money"; import { Money } from "@spt/models/enums/Money";
@ -176,7 +176,7 @@ export class HandbookHelper {
return price ? Math.max(1, Math.round(roubleCurrencyCount / price)) : 0; return price ? Math.max(1, Math.round(roubleCurrencyCount / price)) : 0;
} }
public getCategoryById(handbookId: string): Category { public getCategoryById(handbookId: string): IHandbookCategory {
return this.databaseService.getHandbook().Categories.find((category) => category.Id === handbookId); return this.databaseService.getHandbook().Categories.find((category) => category.Id === handbookId);
} }
} }

View File

@ -1,9 +1,9 @@
export interface IHandbookBase { export interface IHandbookBase {
Categories: Category[]; Categories: IHandbookCategory[];
Items: HandbookItem[]; Items: IHandbookItem[];
} }
export interface Category { export interface IHandbookCategory {
Id: string; Id: string;
ParentId?: string; ParentId?: string;
Icon: string; Icon: string;
@ -11,7 +11,7 @@ export interface Category {
Order: string; Order: string;
} }
export interface HandbookItem { export interface IHandbookItem {
Id: string; Id: string;
ParentId: string; ParentId: string;
Price: number; Price: number;

View File

@ -5,7 +5,7 @@ import { PresetHelper } from "@spt/helpers/PresetHelper";
import { TraderHelper } from "@spt/helpers/TraderHelper"; import { TraderHelper } from "@spt/helpers/TraderHelper";
import { MinMax } from "@spt/models/common/MinMax"; import { MinMax } from "@spt/models/common/MinMax";
import { IPreset } from "@spt/models/eft/common/IGlobals"; import { IPreset } from "@spt/models/eft/common/IGlobals";
import { HandbookItem } from "@spt/models/eft/common/tables/IHandbookBase"; import { IHandbookItem } from "@spt/models/eft/common/tables/IHandbookBase";
import { Item } from "@spt/models/eft/common/tables/IItem"; import { Item } from "@spt/models/eft/common/tables/IItem";
import { IBarterScheme } from "@spt/models/eft/common/tables/ITrader"; import { IBarterScheme } from "@spt/models/eft/common/tables/ITrader";
import { BaseClasses } from "@spt/models/enums/BaseClasses"; import { BaseClasses } from "@spt/models/enums/BaseClasses";
@ -327,7 +327,7 @@ export class RagfairPriceService implements OnLoad {
* @returns Adjusted price of item * @returns Adjusted price of item
*/ */
protected adjustUnreasonablePrice( protected adjustUnreasonablePrice(
handbookPrices: HandbookItem[], handbookPrices: IHandbookItem[],
unreasonableItemChange: IUnreasonableModPrices, unreasonableItemChange: IUnreasonableModPrices,
itemTpl: string, itemTpl: string,
price: number, price: number,