Update types
This commit is contained in:
parent
ac6418feda
commit
ad0bae5e51
@ -1,4 +1,4 @@
|
||||
# Mod examples for v3.7.5
|
||||
# Mod examples for v3.7.6
|
||||
|
||||
A collection of example mods that perform typical actions in SPT
|
||||
|
||||
|
@ -86,11 +86,11 @@ export declare class DialogueCallbacks implements OnUpdate {
|
||||
/** Handle client/friend/ignore/set */
|
||||
ignoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
/** Handle client/friend/ignore/remove */
|
||||
unIgnoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
clearMail(url: string, request: IClearMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
removeMail(url: string, request: IRemoveMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
onUpdate(timeSinceLastRun: number): Promise<boolean>;
|
||||
|
@ -9,6 +9,7 @@ import { IGameKeepAliveResponse } from "@spt-aki/models/eft/game/IGameKeepAliveR
|
||||
import { IGameLogoutResponseData } from "@spt-aki/models/eft/game/IGameLogoutResponseData";
|
||||
import { IGameStartResponse } from "@spt-aki/models/eft/game/IGameStartResponse";
|
||||
import { IGetRaidTimeRequest } from "@spt-aki/models/eft/game/IGetRaidTimeRequest";
|
||||
import { IGetRaidTimeResponse } from "@spt-aki/models/eft/game/IGetRaidTimeResponse";
|
||||
import { IReportNicknameRequestData } from "@spt-aki/models/eft/game/IReportNicknameRequestData";
|
||||
import { IServerDetails } from "@spt-aki/models/eft/game/IServerDetails";
|
||||
import { IVersionValidateRequestData } from "@spt-aki/models/eft/game/IVersionValidateRequestData";
|
||||
@ -73,5 +74,5 @@ export declare class GameCallbacks implements OnLoad {
|
||||
* Handle singleplayer/settings/getRaidTime
|
||||
* @returns string
|
||||
*/
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): any;
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): IGetRaidTimeResponse;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import { ICancelGroupInviteRequest } from "@spt-aki/models/eft/match/ICancelGrou
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -58,7 +59,7 @@ export declare class MatchCallbacks {
|
||||
* Handle client/match/group/status
|
||||
* @returns
|
||||
*/
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<IGetGroupStatusResponse>;
|
||||
/** Handle client/match/group/create */
|
||||
createGroup(url: string, info: ICreateGroupRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
/** Handle client/match/group/delete */
|
||||
|
@ -5,6 +5,7 @@ import { IGetBodyResponseData } from "@spt-aki/models/eft/httpResponse/IGetBodyR
|
||||
import { INullResponseData } from "@spt-aki/models/eft/httpResponse/INullResponseData";
|
||||
import { IGetMiniProfileRequestData } from "@spt-aki/models/eft/launcher/IGetMiniProfileRequestData";
|
||||
import { GetProfileStatusResponseData } from "@spt-aki/models/eft/profile/GetProfileStatusResponseData";
|
||||
import { ICreateProfileResponse } from "@spt-aki/models/eft/profile/ICreateProfileResponse";
|
||||
import { IGetProfileSettingsRequest } from "@spt-aki/models/eft/profile/IGetProfileSettingsRequest";
|
||||
import { IProfileChangeNicknameRequestData } from "@spt-aki/models/eft/profile/IProfileChangeNicknameRequestData";
|
||||
import { IProfileChangeVoiceRequestData } from "@spt-aki/models/eft/profile/IProfileChangeVoiceRequestData";
|
||||
@ -23,7 +24,7 @@ export declare class ProfileCallbacks {
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
*/
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<ICreateProfileResponse>;
|
||||
/**
|
||||
* Handle client/game/profile/list
|
||||
* Get the complete player profile (scav + pmc character)
|
||||
|
@ -11,6 +11,8 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { IRemoveOfferRequestData } from "@spt-aki/models/eft/ragfair/IRemoveOfferRequestData";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { ISendRagfairReportRequestData } from "@spt-aki/models/eft/ragfair/ISendRagfairReportRequestData";
|
||||
@ -57,4 +59,6 @@ export declare class RagfairCallbacks implements OnLoad, OnUpdate {
|
||||
/** Handle client/reports/ragfair/send */
|
||||
sendReport(url: string, info: ISendRagfairReportRequestData, sessionID: string): INullResponseData;
|
||||
storePlayerOfferTaxAmount(url: string, request: IStorePlayerOfferTaxAmountRequestData, sessionId: string): INullResponseData;
|
||||
/** Handle client/ragfair/offer/findbyid */
|
||||
getFleaOfferById(url: string, request: IGetRagfairOfferByIdRequest, sessionID: string): IGetBodyResponseData<IRagfairOffer>;
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { DialogueHelper } from "@spt-aki/helpers/DialogueHelper";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { IGetAllAttachmentsResponse } from "@spt-aki/models/eft/dialog/IGetAllAttachmentsResponse";
|
||||
import { IGetFriendListDataResponse } from "@spt-aki/models/eft/dialog/IGetFriendListDataResponse";
|
||||
import { IGetMailDialogViewRequestData } from "@spt-aki/models/eft/dialog/IGetMailDialogViewRequestData";
|
||||
@ -7,28 +7,21 @@ import { IGetMailDialogViewResponseData } from "@spt-aki/models/eft/dialog/IGetM
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { Dialogue, DialogueInfo, IAkiProfile, IUserDialogInfo, Message } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { MessageType } from "@spt-aki/models/enums/MessageType";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { SaveServer } from "@spt-aki/servers/SaveServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
import { TimeUtil } from "@spt-aki/utils/TimeUtil";
|
||||
export declare class DialogueController {
|
||||
protected logger: ILogger;
|
||||
protected saveServer: SaveServer;
|
||||
protected timeUtil: TimeUtil;
|
||||
protected dialogueHelper: DialogueHelper;
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected hashUtil: HashUtil;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, hashUtil: HashUtil, configServer: ConfigServer);
|
||||
protected dialogueChatBots: IDialogueChatBot[];
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, mailSendService: MailSendService, configServer: ConfigServer, dialogueChatBots: IDialogueChatBot[]);
|
||||
registerChatBot(chatBot: IDialogueChatBot): void;
|
||||
/** Handle onUpdate spt event */
|
||||
update(): void;
|
||||
/**
|
||||
@ -122,13 +115,6 @@ export declare class DialogueController {
|
||||
getAllAttachments(dialogueId: string, sessionId: string): IGetAllAttachmentsResponse;
|
||||
/** client/mail/msg/send */
|
||||
sendMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
protected handleChatWithSPTFriend(sessionId: string, request: ISendMessageRequest): void;
|
||||
protected getSptFriendData(friendId?: string): IUserDialogInfo;
|
||||
/**
|
||||
* Get messages from a specific dialog that have items not expired
|
||||
* @param sessionId Session id
|
||||
|
@ -6,6 +6,7 @@ import { IPmcData } from "@spt-aki/models/eft/common/IPmcData";
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -56,7 +57,7 @@ export declare class MatchController {
|
||||
/** Handle match/group/start_game */
|
||||
joinMatch(info: IJoinMatchRequestData, sessionId: string): IJoinMatchResult;
|
||||
/** Handle client/match/group/status */
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): any;
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): IGetGroupStatusResponse;
|
||||
/**
|
||||
* Handle /client/raid/configuration
|
||||
* @param request Raid config request
|
||||
|
@ -54,8 +54,11 @@ export declare class ProfileController {
|
||||
getCompleteProfile(sessionID: string): IPmcData[];
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
* @param info Client reqeust object
|
||||
* @param sessionID Player id
|
||||
* @returns Profiles _id value
|
||||
*/
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): void;
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): string;
|
||||
/**
|
||||
* Delete a profile
|
||||
* @param sessionID Id of profile to delete
|
||||
|
@ -19,6 +19,7 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { IProcessBuyTradeRequestData } from "@spt-aki/models/eft/trade/IProcessBuyTradeRequestData";
|
||||
@ -69,6 +70,13 @@ export declare class RagfairController {
|
||||
protected ragfairConfig: IRagfairConfig;
|
||||
constructor(logger: ILogger, timeUtil: TimeUtil, httpResponse: HttpResponseUtil, eventOutputHolder: EventOutputHolder, ragfairServer: RagfairServer, ragfairPriceService: RagfairPriceService, databaseServer: DatabaseServer, itemHelper: ItemHelper, saveServer: SaveServer, ragfairSellHelper: RagfairSellHelper, ragfairTaxService: RagfairTaxService, ragfairSortHelper: RagfairSortHelper, ragfairOfferHelper: RagfairOfferHelper, profileHelper: ProfileHelper, paymentService: PaymentService, handbookHelper: HandbookHelper, paymentHelper: PaymentHelper, inventoryHelper: InventoryHelper, traderHelper: TraderHelper, ragfairHelper: RagfairHelper, ragfairOfferService: RagfairOfferService, ragfairRequiredItemsService: RagfairRequiredItemsService, ragfairOfferGenerator: RagfairOfferGenerator, localisationService: LocalisationService, configServer: ConfigServer);
|
||||
getOffers(sessionID: string, searchRequest: ISearchRequestData): IGetOffersResult;
|
||||
/**
|
||||
* Handle client/ragfair/offer/findbyid
|
||||
* @param sessionId Player id
|
||||
* @param request Request data
|
||||
* @returns IRagfairOffer
|
||||
*/
|
||||
getOfferById(sessionId: string, request: IGetRagfairOfferByIdRequest): IRagfairOffer;
|
||||
/**
|
||||
* Get offers for the client based on type of search being performed
|
||||
* @param searchRequest Client search request data
|
||||
@ -111,6 +119,9 @@ export declare class RagfairController {
|
||||
protected setTraderOfferStackSize(offer: IRagfairOffer): void;
|
||||
protected isLinkedSearch(info: ISearchRequestData): boolean;
|
||||
protected isRequiredSearch(info: ISearchRequestData): boolean;
|
||||
/**
|
||||
* Check all profiles and sell player offers / send player money for listing if it sold
|
||||
*/
|
||||
update(): void;
|
||||
/**
|
||||
* Called when creating an offer on flea, fills values in top right corner
|
||||
|
@ -45,6 +45,8 @@ export declare class RagfairOfferGenerator {
|
||||
tpl: string;
|
||||
price: number;
|
||||
}[];
|
||||
/** Internal counter to ensure each offer created has a unique value for its intId property */
|
||||
protected offerCounter: number;
|
||||
constructor(logger: ILogger, jsonUtil: JsonUtil, hashUtil: HashUtil, randomUtil: RandomUtil, timeUtil: TimeUtil, databaseServer: DatabaseServer, ragfairServerHelper: RagfairServerHelper, handbookHelper: HandbookHelper, saveServer: SaveServer, presetHelper: PresetHelper, ragfairAssortGenerator: RagfairAssortGenerator, ragfairOfferService: RagfairOfferService, ragfairPriceService: RagfairPriceService, localisationService: LocalisationService, paymentHelper: PaymentHelper, fenceService: FenceService, itemHelper: ItemHelper, configServer: ConfigServer);
|
||||
/**
|
||||
* Create a flea offer and store it in the Ragfair server offers array
|
||||
|
8
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
8
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ICommandoCommand {
|
||||
getCommandPrefix(): string;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
15
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
export declare class SptCommandoCommands implements ICommandoCommand {
|
||||
protected configServer: ConfigServer;
|
||||
protected sptCommands: ISptCommand[];
|
||||
constructor(configServer: ConfigServer, sptCommands: ISptCommand[]);
|
||||
registerSptCommandoCommand(command: ISptCommand): void;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommandPrefix(): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
21
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
21
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { PresetHelper } from "@spt-aki/helpers/PresetHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
export declare class GiveSptCommand implements ISptCommand {
|
||||
protected logger: ILogger;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected presetHelper: PresetHelper;
|
||||
protected mailSendService: MailSendService;
|
||||
constructor(logger: ILogger, itemHelper: ItemHelper, hashUtil: HashUtil, jsonUtil: JsonUtil, presetHelper: PresetHelper, mailSendService: MailSendService);
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
7
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommands/ISptCommand.d.ts
vendored
Normal file
7
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/Commando/SptCommands/ISptCommand.d.ts
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ISptCommand {
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
15
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
export declare class CommandoDialogueChatBot implements IDialogueChatBot {
|
||||
protected logger: ILogger;
|
||||
protected mailSendService: MailSendService;
|
||||
protected commandoCommands: ICommandoCommand[];
|
||||
constructor(logger: ILogger, mailSendService: MailSendService, commandoCommands: ICommandoCommand[]);
|
||||
registerCommandoCommand(commandoCommand: ICommandoCommand): void;
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
6
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
6
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface IDialogueChatBot {
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
25
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
25
TypeScript/10ScopesAndTypes/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
export declare class SptDialogueChatBot implements IDialogueChatBot {
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, configServer: ConfigServer);
|
||||
getChatBot(): IUserDialogInfo;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -150,6 +150,12 @@ export declare class RagfairOfferHelper {
|
||||
* @returns True = should be shown to player
|
||||
*/
|
||||
isDisplayableOffer(searchRequest: ISearchRequestData, itemsToAdd: string[], traderAssorts: Record<string, ITraderAssort>, offer: IRagfairOffer, pmcProfile: IPmcData): boolean;
|
||||
/**
|
||||
* Does the passed in item have a condition property
|
||||
* @param item Item to check
|
||||
* @returns True if has condition
|
||||
*/
|
||||
protected isConditionItem(item: Item): boolean;
|
||||
/**
|
||||
* Is items quality value within desired range
|
||||
* @param item Item to check quality of
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface ICurrentGroupResponse {
|
||||
squad: any[];
|
||||
squad: ICurrentGroupSquadMember[];
|
||||
}
|
||||
export interface ICurrentGroupSquadMember {
|
||||
_id: string;
|
||||
|
19
TypeScript/10ScopesAndTypes/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
19
TypeScript/10ScopesAndTypes/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface IGetGroupStatusResponse {
|
||||
players: IPlayer[];
|
||||
maxPveCountExceeded: boolean;
|
||||
}
|
||||
export interface IPlayer {
|
||||
aid: string;
|
||||
_id: string;
|
||||
lookingGroup: boolean;
|
||||
IsLeader: boolean;
|
||||
IsReady: boolean;
|
||||
Info: ICurrentGroupMemberInfo;
|
||||
}
|
||||
export interface ICurrentGroupMemberInfo {
|
||||
Nickname: string;
|
||||
Side: string;
|
||||
Level: string;
|
||||
MemberCategory: MemberCategory;
|
||||
}
|
3
TypeScript/10ScopesAndTypes/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
3
TypeScript/10ScopesAndTypes/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
export interface ICreateProfileResponse {
|
||||
uid: string;
|
||||
}
|
3
TypeScript/10ScopesAndTypes/types/models/eft/ragfair/IGetRagfairOfferByIdRequest.d.ts
vendored
Normal file
3
TypeScript/10ScopesAndTypes/types/models/eft/ragfair/IGetRagfairOfferByIdRequest.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
export interface IGetRagfairOfferByIdRequest {
|
||||
id: number;
|
||||
}
|
@ -24,4 +24,14 @@ export interface IGameFixes {
|
||||
}
|
||||
export interface IServerFeatures {
|
||||
autoInstallModDependencies: boolean;
|
||||
compressProfile: boolean;
|
||||
chatbotFeatures: IChatbotFeatures;
|
||||
}
|
||||
export interface IChatbotFeatures {
|
||||
sptFriendEnabled: boolean;
|
||||
commandoEnabled: boolean;
|
||||
commandoFeatures: ICommandoFeatures;
|
||||
}
|
||||
export interface ICommandoFeatures {
|
||||
giveCommandEnabled: boolean;
|
||||
}
|
||||
|
@ -98,10 +98,13 @@ export interface IScavRaidTimeConfigSettings {
|
||||
export interface IScavRaidTimeLocationSettings {
|
||||
/** Should loot be reduced by same percent length of raid is reduced by */
|
||||
reduceLootByPercent: boolean;
|
||||
/** Smallest % of container loot that should be spawned */
|
||||
minStaticLootPercent: number;
|
||||
/** Smallest % of loose loot that should be spawned */
|
||||
minDynamicLootPercent: number;
|
||||
/** Chance raid time is reduced */
|
||||
reducedChancePercent: number;
|
||||
/** How much should raid time be reduced - weighted */
|
||||
reductionPercentWeights: Record<string, number>;
|
||||
/** Should bot waves be removed / spawn times be adjusted */
|
||||
adjustWaves: boolean;
|
||||
|
@ -5,6 +5,7 @@ import { LocalisationService } from "@spt-aki/services/LocalisationService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
import { VFS } from "@spt-aki/utils/VFS";
|
||||
import { ConfigServer } from "./ConfigServer";
|
||||
export declare class SaveServer {
|
||||
protected vfs: VFS;
|
||||
protected saveLoadRouters: SaveLoadRouter[];
|
||||
@ -12,11 +13,12 @@ export declare class SaveServer {
|
||||
protected hashUtil: HashUtil;
|
||||
protected localisationService: LocalisationService;
|
||||
protected logger: ILogger;
|
||||
protected configServer: ConfigServer;
|
||||
protected profileFilepath: string;
|
||||
protected profiles: {};
|
||||
protected onBeforeSaveCallbacks: {};
|
||||
protected saveMd5: {};
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger);
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger, configServer: ConfigServer);
|
||||
/**
|
||||
* Add callback to occur prior to saving profile changes
|
||||
* @param id Id for save callback
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { ITemplateItem, Props } from "@spt-aki/models/eft/common/tables/ITemplateItem";
|
||||
import { CreateItemResult, LocaleDetails, NewItemDetails, NewItemFromCloneDetails } from "@spt-aki/models/spt/mod/NewItemDetails";
|
||||
import { IDatabaseTables } from "@spt-aki/models/spt/server/IDatabaseTables";
|
||||
@ -10,8 +11,9 @@ export declare class CustomItemService {
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected databaseServer: DatabaseServer;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected tables: IDatabaseTables;
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer);
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer, itemHelper: ItemHelper);
|
||||
/**
|
||||
* Create a new item from a cloned item base
|
||||
* WARNING - If no item id is supplied, an id will be generated, this id will be random every time you add an item and will not be the same on each subsequent server start
|
||||
@ -77,4 +79,11 @@ export declare class CustomItemService {
|
||||
* @param fleaPriceRoubles Price of the new item
|
||||
*/
|
||||
protected addToFleaPriceDb(newItemId: string, fleaPriceRoubles: number): void;
|
||||
/**
|
||||
* Add a custom weapon to PMCs loadout
|
||||
* @param weaponTpl Custom weapon tpl to add to PMCs
|
||||
* @param weaponWeight The weighting for the weapon to be picked vs other weapons
|
||||
* @param weaponSlot The slot the weapon should be added to (e.g. FirstPrimaryWeapon/SecondPrimaryWeapon/Holster)
|
||||
*/
|
||||
addCustomWeaponToPMCs(weaponTpl: string, weaponWeight: number, weaponSlot: string): void;
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ export declare class HttpResponseUtil {
|
||||
* @param errmsg
|
||||
* @returns
|
||||
*/
|
||||
getBody<T>(data: T, err?: number, errmsg?: any): IGetBodyResponseData<T>;
|
||||
getBody<T>(data: T, err?: number, errmsg?: any, sanitize?: boolean): IGetBodyResponseData<T>;
|
||||
getUnclearedBody(data: any, err?: number, errmsg?: any): string;
|
||||
emptyResponse(): IGetBodyResponseData<string>;
|
||||
nullResponse(): INullResponseData;
|
||||
|
@ -86,11 +86,11 @@ export declare class DialogueCallbacks implements OnUpdate {
|
||||
/** Handle client/friend/ignore/set */
|
||||
ignoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
/** Handle client/friend/ignore/remove */
|
||||
unIgnoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
clearMail(url: string, request: IClearMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
removeMail(url: string, request: IRemoveMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
onUpdate(timeSinceLastRun: number): Promise<boolean>;
|
||||
|
@ -9,6 +9,7 @@ import { IGameKeepAliveResponse } from "@spt-aki/models/eft/game/IGameKeepAliveR
|
||||
import { IGameLogoutResponseData } from "@spt-aki/models/eft/game/IGameLogoutResponseData";
|
||||
import { IGameStartResponse } from "@spt-aki/models/eft/game/IGameStartResponse";
|
||||
import { IGetRaidTimeRequest } from "@spt-aki/models/eft/game/IGetRaidTimeRequest";
|
||||
import { IGetRaidTimeResponse } from "@spt-aki/models/eft/game/IGetRaidTimeResponse";
|
||||
import { IReportNicknameRequestData } from "@spt-aki/models/eft/game/IReportNicknameRequestData";
|
||||
import { IServerDetails } from "@spt-aki/models/eft/game/IServerDetails";
|
||||
import { IVersionValidateRequestData } from "@spt-aki/models/eft/game/IVersionValidateRequestData";
|
||||
@ -73,5 +74,5 @@ export declare class GameCallbacks implements OnLoad {
|
||||
* Handle singleplayer/settings/getRaidTime
|
||||
* @returns string
|
||||
*/
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): any;
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): IGetRaidTimeResponse;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import { ICancelGroupInviteRequest } from "@spt-aki/models/eft/match/ICancelGrou
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -58,7 +59,7 @@ export declare class MatchCallbacks {
|
||||
* Handle client/match/group/status
|
||||
* @returns
|
||||
*/
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<IGetGroupStatusResponse>;
|
||||
/** Handle client/match/group/create */
|
||||
createGroup(url: string, info: ICreateGroupRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
/** Handle client/match/group/delete */
|
||||
|
@ -5,6 +5,7 @@ import { IGetBodyResponseData } from "@spt-aki/models/eft/httpResponse/IGetBodyR
|
||||
import { INullResponseData } from "@spt-aki/models/eft/httpResponse/INullResponseData";
|
||||
import { IGetMiniProfileRequestData } from "@spt-aki/models/eft/launcher/IGetMiniProfileRequestData";
|
||||
import { GetProfileStatusResponseData } from "@spt-aki/models/eft/profile/GetProfileStatusResponseData";
|
||||
import { ICreateProfileResponse } from "@spt-aki/models/eft/profile/ICreateProfileResponse";
|
||||
import { IGetProfileSettingsRequest } from "@spt-aki/models/eft/profile/IGetProfileSettingsRequest";
|
||||
import { IProfileChangeNicknameRequestData } from "@spt-aki/models/eft/profile/IProfileChangeNicknameRequestData";
|
||||
import { IProfileChangeVoiceRequestData } from "@spt-aki/models/eft/profile/IProfileChangeVoiceRequestData";
|
||||
@ -23,7 +24,7 @@ export declare class ProfileCallbacks {
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
*/
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<ICreateProfileResponse>;
|
||||
/**
|
||||
* Handle client/game/profile/list
|
||||
* Get the complete player profile (scav + pmc character)
|
||||
|
@ -11,6 +11,8 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { IRemoveOfferRequestData } from "@spt-aki/models/eft/ragfair/IRemoveOfferRequestData";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { ISendRagfairReportRequestData } from "@spt-aki/models/eft/ragfair/ISendRagfairReportRequestData";
|
||||
@ -57,4 +59,6 @@ export declare class RagfairCallbacks implements OnLoad, OnUpdate {
|
||||
/** Handle client/reports/ragfair/send */
|
||||
sendReport(url: string, info: ISendRagfairReportRequestData, sessionID: string): INullResponseData;
|
||||
storePlayerOfferTaxAmount(url: string, request: IStorePlayerOfferTaxAmountRequestData, sessionId: string): INullResponseData;
|
||||
/** Handle client/ragfair/offer/findbyid */
|
||||
getFleaOfferById(url: string, request: IGetRagfairOfferByIdRequest, sessionID: string): IGetBodyResponseData<IRagfairOffer>;
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { DialogueHelper } from "@spt-aki/helpers/DialogueHelper";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { IGetAllAttachmentsResponse } from "@spt-aki/models/eft/dialog/IGetAllAttachmentsResponse";
|
||||
import { IGetFriendListDataResponse } from "@spt-aki/models/eft/dialog/IGetFriendListDataResponse";
|
||||
import { IGetMailDialogViewRequestData } from "@spt-aki/models/eft/dialog/IGetMailDialogViewRequestData";
|
||||
@ -7,28 +7,21 @@ import { IGetMailDialogViewResponseData } from "@spt-aki/models/eft/dialog/IGetM
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { Dialogue, DialogueInfo, IAkiProfile, IUserDialogInfo, Message } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { MessageType } from "@spt-aki/models/enums/MessageType";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { SaveServer } from "@spt-aki/servers/SaveServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
import { TimeUtil } from "@spt-aki/utils/TimeUtil";
|
||||
export declare class DialogueController {
|
||||
protected logger: ILogger;
|
||||
protected saveServer: SaveServer;
|
||||
protected timeUtil: TimeUtil;
|
||||
protected dialogueHelper: DialogueHelper;
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected hashUtil: HashUtil;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, hashUtil: HashUtil, configServer: ConfigServer);
|
||||
protected dialogueChatBots: IDialogueChatBot[];
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, mailSendService: MailSendService, configServer: ConfigServer, dialogueChatBots: IDialogueChatBot[]);
|
||||
registerChatBot(chatBot: IDialogueChatBot): void;
|
||||
/** Handle onUpdate spt event */
|
||||
update(): void;
|
||||
/**
|
||||
@ -122,13 +115,6 @@ export declare class DialogueController {
|
||||
getAllAttachments(dialogueId: string, sessionId: string): IGetAllAttachmentsResponse;
|
||||
/** client/mail/msg/send */
|
||||
sendMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
protected handleChatWithSPTFriend(sessionId: string, request: ISendMessageRequest): void;
|
||||
protected getSptFriendData(friendId?: string): IUserDialogInfo;
|
||||
/**
|
||||
* Get messages from a specific dialog that have items not expired
|
||||
* @param sessionId Session id
|
||||
|
@ -6,6 +6,7 @@ import { IPmcData } from "@spt-aki/models/eft/common/IPmcData";
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -56,7 +57,7 @@ export declare class MatchController {
|
||||
/** Handle match/group/start_game */
|
||||
joinMatch(info: IJoinMatchRequestData, sessionId: string): IJoinMatchResult;
|
||||
/** Handle client/match/group/status */
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): any;
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): IGetGroupStatusResponse;
|
||||
/**
|
||||
* Handle /client/raid/configuration
|
||||
* @param request Raid config request
|
||||
|
@ -54,8 +54,11 @@ export declare class ProfileController {
|
||||
getCompleteProfile(sessionID: string): IPmcData[];
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
* @param info Client reqeust object
|
||||
* @param sessionID Player id
|
||||
* @returns Profiles _id value
|
||||
*/
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): void;
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): string;
|
||||
/**
|
||||
* Delete a profile
|
||||
* @param sessionID Id of profile to delete
|
||||
|
@ -19,6 +19,7 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { IProcessBuyTradeRequestData } from "@spt-aki/models/eft/trade/IProcessBuyTradeRequestData";
|
||||
@ -69,6 +70,13 @@ export declare class RagfairController {
|
||||
protected ragfairConfig: IRagfairConfig;
|
||||
constructor(logger: ILogger, timeUtil: TimeUtil, httpResponse: HttpResponseUtil, eventOutputHolder: EventOutputHolder, ragfairServer: RagfairServer, ragfairPriceService: RagfairPriceService, databaseServer: DatabaseServer, itemHelper: ItemHelper, saveServer: SaveServer, ragfairSellHelper: RagfairSellHelper, ragfairTaxService: RagfairTaxService, ragfairSortHelper: RagfairSortHelper, ragfairOfferHelper: RagfairOfferHelper, profileHelper: ProfileHelper, paymentService: PaymentService, handbookHelper: HandbookHelper, paymentHelper: PaymentHelper, inventoryHelper: InventoryHelper, traderHelper: TraderHelper, ragfairHelper: RagfairHelper, ragfairOfferService: RagfairOfferService, ragfairRequiredItemsService: RagfairRequiredItemsService, ragfairOfferGenerator: RagfairOfferGenerator, localisationService: LocalisationService, configServer: ConfigServer);
|
||||
getOffers(sessionID: string, searchRequest: ISearchRequestData): IGetOffersResult;
|
||||
/**
|
||||
* Handle client/ragfair/offer/findbyid
|
||||
* @param sessionId Player id
|
||||
* @param request Request data
|
||||
* @returns IRagfairOffer
|
||||
*/
|
||||
getOfferById(sessionId: string, request: IGetRagfairOfferByIdRequest): IRagfairOffer;
|
||||
/**
|
||||
* Get offers for the client based on type of search being performed
|
||||
* @param searchRequest Client search request data
|
||||
@ -111,6 +119,9 @@ export declare class RagfairController {
|
||||
protected setTraderOfferStackSize(offer: IRagfairOffer): void;
|
||||
protected isLinkedSearch(info: ISearchRequestData): boolean;
|
||||
protected isRequiredSearch(info: ISearchRequestData): boolean;
|
||||
/**
|
||||
* Check all profiles and sell player offers / send player money for listing if it sold
|
||||
*/
|
||||
update(): void;
|
||||
/**
|
||||
* Called when creating an offer on flea, fills values in top right corner
|
||||
|
@ -45,6 +45,8 @@ export declare class RagfairOfferGenerator {
|
||||
tpl: string;
|
||||
price: number;
|
||||
}[];
|
||||
/** Internal counter to ensure each offer created has a unique value for its intId property */
|
||||
protected offerCounter: number;
|
||||
constructor(logger: ILogger, jsonUtil: JsonUtil, hashUtil: HashUtil, randomUtil: RandomUtil, timeUtil: TimeUtil, databaseServer: DatabaseServer, ragfairServerHelper: RagfairServerHelper, handbookHelper: HandbookHelper, saveServer: SaveServer, presetHelper: PresetHelper, ragfairAssortGenerator: RagfairAssortGenerator, ragfairOfferService: RagfairOfferService, ragfairPriceService: RagfairPriceService, localisationService: LocalisationService, paymentHelper: PaymentHelper, fenceService: FenceService, itemHelper: ItemHelper, configServer: ConfigServer);
|
||||
/**
|
||||
* Create a flea offer and store it in the Ragfair server offers array
|
||||
|
8
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
8
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ICommandoCommand {
|
||||
getCommandPrefix(): string;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
15
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
export declare class SptCommandoCommands implements ICommandoCommand {
|
||||
protected configServer: ConfigServer;
|
||||
protected sptCommands: ISptCommand[];
|
||||
constructor(configServer: ConfigServer, sptCommands: ISptCommand[]);
|
||||
registerSptCommandoCommand(command: ISptCommand): void;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommandPrefix(): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
21
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
21
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { PresetHelper } from "@spt-aki/helpers/PresetHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
export declare class GiveSptCommand implements ISptCommand {
|
||||
protected logger: ILogger;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected presetHelper: PresetHelper;
|
||||
protected mailSendService: MailSendService;
|
||||
constructor(logger: ILogger, itemHelper: ItemHelper, hashUtil: HashUtil, jsonUtil: JsonUtil, presetHelper: PresetHelper, mailSendService: MailSendService);
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -0,0 +1,7 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ISptCommand {
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
15
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
export declare class CommandoDialogueChatBot implements IDialogueChatBot {
|
||||
protected logger: ILogger;
|
||||
protected mailSendService: MailSendService;
|
||||
protected commandoCommands: ICommandoCommand[];
|
||||
constructor(logger: ILogger, mailSendService: MailSendService, commandoCommands: ICommandoCommand[]);
|
||||
registerCommandoCommand(commandoCommand: ICommandoCommand): void;
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
6
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
6
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface IDialogueChatBot {
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
25
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
25
TypeScript/11BundleLoadingSample/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
export declare class SptDialogueChatBot implements IDialogueChatBot {
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, configServer: ConfigServer);
|
||||
getChatBot(): IUserDialogInfo;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -150,6 +150,12 @@ export declare class RagfairOfferHelper {
|
||||
* @returns True = should be shown to player
|
||||
*/
|
||||
isDisplayableOffer(searchRequest: ISearchRequestData, itemsToAdd: string[], traderAssorts: Record<string, ITraderAssort>, offer: IRagfairOffer, pmcProfile: IPmcData): boolean;
|
||||
/**
|
||||
* Does the passed in item have a condition property
|
||||
* @param item Item to check
|
||||
* @returns True if has condition
|
||||
*/
|
||||
protected isConditionItem(item: Item): boolean;
|
||||
/**
|
||||
* Is items quality value within desired range
|
||||
* @param item Item to check quality of
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface ICurrentGroupResponse {
|
||||
squad: any[];
|
||||
squad: ICurrentGroupSquadMember[];
|
||||
}
|
||||
export interface ICurrentGroupSquadMember {
|
||||
_id: string;
|
||||
|
19
TypeScript/11BundleLoadingSample/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
19
TypeScript/11BundleLoadingSample/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface IGetGroupStatusResponse {
|
||||
players: IPlayer[];
|
||||
maxPveCountExceeded: boolean;
|
||||
}
|
||||
export interface IPlayer {
|
||||
aid: string;
|
||||
_id: string;
|
||||
lookingGroup: boolean;
|
||||
IsLeader: boolean;
|
||||
IsReady: boolean;
|
||||
Info: ICurrentGroupMemberInfo;
|
||||
}
|
||||
export interface ICurrentGroupMemberInfo {
|
||||
Nickname: string;
|
||||
Side: string;
|
||||
Level: string;
|
||||
MemberCategory: MemberCategory;
|
||||
}
|
3
TypeScript/11BundleLoadingSample/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
3
TypeScript/11BundleLoadingSample/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
export interface ICreateProfileResponse {
|
||||
uid: string;
|
||||
}
|
3
TypeScript/11BundleLoadingSample/types/models/eft/ragfair/IGetRagfairOfferByIdRequest.d.ts
vendored
Normal file
3
TypeScript/11BundleLoadingSample/types/models/eft/ragfair/IGetRagfairOfferByIdRequest.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
export interface IGetRagfairOfferByIdRequest {
|
||||
id: number;
|
||||
}
|
@ -24,4 +24,14 @@ export interface IGameFixes {
|
||||
}
|
||||
export interface IServerFeatures {
|
||||
autoInstallModDependencies: boolean;
|
||||
compressProfile: boolean;
|
||||
chatbotFeatures: IChatbotFeatures;
|
||||
}
|
||||
export interface IChatbotFeatures {
|
||||
sptFriendEnabled: boolean;
|
||||
commandoEnabled: boolean;
|
||||
commandoFeatures: ICommandoFeatures;
|
||||
}
|
||||
export interface ICommandoFeatures {
|
||||
giveCommandEnabled: boolean;
|
||||
}
|
||||
|
@ -98,10 +98,13 @@ export interface IScavRaidTimeConfigSettings {
|
||||
export interface IScavRaidTimeLocationSettings {
|
||||
/** Should loot be reduced by same percent length of raid is reduced by */
|
||||
reduceLootByPercent: boolean;
|
||||
/** Smallest % of container loot that should be spawned */
|
||||
minStaticLootPercent: number;
|
||||
/** Smallest % of loose loot that should be spawned */
|
||||
minDynamicLootPercent: number;
|
||||
/** Chance raid time is reduced */
|
||||
reducedChancePercent: number;
|
||||
/** How much should raid time be reduced - weighted */
|
||||
reductionPercentWeights: Record<string, number>;
|
||||
/** Should bot waves be removed / spawn times be adjusted */
|
||||
adjustWaves: boolean;
|
||||
|
@ -5,6 +5,7 @@ import { LocalisationService } from "@spt-aki/services/LocalisationService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
import { VFS } from "@spt-aki/utils/VFS";
|
||||
import { ConfigServer } from "./ConfigServer";
|
||||
export declare class SaveServer {
|
||||
protected vfs: VFS;
|
||||
protected saveLoadRouters: SaveLoadRouter[];
|
||||
@ -12,11 +13,12 @@ export declare class SaveServer {
|
||||
protected hashUtil: HashUtil;
|
||||
protected localisationService: LocalisationService;
|
||||
protected logger: ILogger;
|
||||
protected configServer: ConfigServer;
|
||||
protected profileFilepath: string;
|
||||
protected profiles: {};
|
||||
protected onBeforeSaveCallbacks: {};
|
||||
protected saveMd5: {};
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger);
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger, configServer: ConfigServer);
|
||||
/**
|
||||
* Add callback to occur prior to saving profile changes
|
||||
* @param id Id for save callback
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { ITemplateItem, Props } from "@spt-aki/models/eft/common/tables/ITemplateItem";
|
||||
import { CreateItemResult, LocaleDetails, NewItemDetails, NewItemFromCloneDetails } from "@spt-aki/models/spt/mod/NewItemDetails";
|
||||
import { IDatabaseTables } from "@spt-aki/models/spt/server/IDatabaseTables";
|
||||
@ -10,8 +11,9 @@ export declare class CustomItemService {
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected databaseServer: DatabaseServer;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected tables: IDatabaseTables;
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer);
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer, itemHelper: ItemHelper);
|
||||
/**
|
||||
* Create a new item from a cloned item base
|
||||
* WARNING - If no item id is supplied, an id will be generated, this id will be random every time you add an item and will not be the same on each subsequent server start
|
||||
@ -77,4 +79,11 @@ export declare class CustomItemService {
|
||||
* @param fleaPriceRoubles Price of the new item
|
||||
*/
|
||||
protected addToFleaPriceDb(newItemId: string, fleaPriceRoubles: number): void;
|
||||
/**
|
||||
* Add a custom weapon to PMCs loadout
|
||||
* @param weaponTpl Custom weapon tpl to add to PMCs
|
||||
* @param weaponWeight The weighting for the weapon to be picked vs other weapons
|
||||
* @param weaponSlot The slot the weapon should be added to (e.g. FirstPrimaryWeapon/SecondPrimaryWeapon/Holster)
|
||||
*/
|
||||
addCustomWeaponToPMCs(weaponTpl: string, weaponWeight: number, weaponSlot: string): void;
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ export declare class HttpResponseUtil {
|
||||
* @param errmsg
|
||||
* @returns
|
||||
*/
|
||||
getBody<T>(data: T, err?: number, errmsg?: any): IGetBodyResponseData<T>;
|
||||
getBody<T>(data: T, err?: number, errmsg?: any, sanitize?: boolean): IGetBodyResponseData<T>;
|
||||
getUnclearedBody(data: any, err?: number, errmsg?: any): string;
|
||||
emptyResponse(): IGetBodyResponseData<string>;
|
||||
nullResponse(): INullResponseData;
|
||||
|
@ -86,11 +86,11 @@ export declare class DialogueCallbacks implements OnUpdate {
|
||||
/** Handle client/friend/ignore/set */
|
||||
ignoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
/** Handle client/friend/ignore/remove */
|
||||
unIgnoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
clearMail(url: string, request: IClearMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
removeMail(url: string, request: IRemoveMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
onUpdate(timeSinceLastRun: number): Promise<boolean>;
|
||||
|
@ -9,6 +9,7 @@ import { IGameKeepAliveResponse } from "@spt-aki/models/eft/game/IGameKeepAliveR
|
||||
import { IGameLogoutResponseData } from "@spt-aki/models/eft/game/IGameLogoutResponseData";
|
||||
import { IGameStartResponse } from "@spt-aki/models/eft/game/IGameStartResponse";
|
||||
import { IGetRaidTimeRequest } from "@spt-aki/models/eft/game/IGetRaidTimeRequest";
|
||||
import { IGetRaidTimeResponse } from "@spt-aki/models/eft/game/IGetRaidTimeResponse";
|
||||
import { IReportNicknameRequestData } from "@spt-aki/models/eft/game/IReportNicknameRequestData";
|
||||
import { IServerDetails } from "@spt-aki/models/eft/game/IServerDetails";
|
||||
import { IVersionValidateRequestData } from "@spt-aki/models/eft/game/IVersionValidateRequestData";
|
||||
@ -73,5 +74,5 @@ export declare class GameCallbacks implements OnLoad {
|
||||
* Handle singleplayer/settings/getRaidTime
|
||||
* @returns string
|
||||
*/
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): any;
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): IGetRaidTimeResponse;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import { ICancelGroupInviteRequest } from "@spt-aki/models/eft/match/ICancelGrou
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -58,7 +59,7 @@ export declare class MatchCallbacks {
|
||||
* Handle client/match/group/status
|
||||
* @returns
|
||||
*/
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<IGetGroupStatusResponse>;
|
||||
/** Handle client/match/group/create */
|
||||
createGroup(url: string, info: ICreateGroupRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
/** Handle client/match/group/delete */
|
||||
|
@ -5,6 +5,7 @@ import { IGetBodyResponseData } from "@spt-aki/models/eft/httpResponse/IGetBodyR
|
||||
import { INullResponseData } from "@spt-aki/models/eft/httpResponse/INullResponseData";
|
||||
import { IGetMiniProfileRequestData } from "@spt-aki/models/eft/launcher/IGetMiniProfileRequestData";
|
||||
import { GetProfileStatusResponseData } from "@spt-aki/models/eft/profile/GetProfileStatusResponseData";
|
||||
import { ICreateProfileResponse } from "@spt-aki/models/eft/profile/ICreateProfileResponse";
|
||||
import { IGetProfileSettingsRequest } from "@spt-aki/models/eft/profile/IGetProfileSettingsRequest";
|
||||
import { IProfileChangeNicknameRequestData } from "@spt-aki/models/eft/profile/IProfileChangeNicknameRequestData";
|
||||
import { IProfileChangeVoiceRequestData } from "@spt-aki/models/eft/profile/IProfileChangeVoiceRequestData";
|
||||
@ -23,7 +24,7 @@ export declare class ProfileCallbacks {
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
*/
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<ICreateProfileResponse>;
|
||||
/**
|
||||
* Handle client/game/profile/list
|
||||
* Get the complete player profile (scav + pmc character)
|
||||
|
@ -11,6 +11,8 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { IRemoveOfferRequestData } from "@spt-aki/models/eft/ragfair/IRemoveOfferRequestData";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { ISendRagfairReportRequestData } from "@spt-aki/models/eft/ragfair/ISendRagfairReportRequestData";
|
||||
@ -57,4 +59,6 @@ export declare class RagfairCallbacks implements OnLoad, OnUpdate {
|
||||
/** Handle client/reports/ragfair/send */
|
||||
sendReport(url: string, info: ISendRagfairReportRequestData, sessionID: string): INullResponseData;
|
||||
storePlayerOfferTaxAmount(url: string, request: IStorePlayerOfferTaxAmountRequestData, sessionId: string): INullResponseData;
|
||||
/** Handle client/ragfair/offer/findbyid */
|
||||
getFleaOfferById(url: string, request: IGetRagfairOfferByIdRequest, sessionID: string): IGetBodyResponseData<IRagfairOffer>;
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { DialogueHelper } from "@spt-aki/helpers/DialogueHelper";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { IGetAllAttachmentsResponse } from "@spt-aki/models/eft/dialog/IGetAllAttachmentsResponse";
|
||||
import { IGetFriendListDataResponse } from "@spt-aki/models/eft/dialog/IGetFriendListDataResponse";
|
||||
import { IGetMailDialogViewRequestData } from "@spt-aki/models/eft/dialog/IGetMailDialogViewRequestData";
|
||||
@ -7,28 +7,21 @@ import { IGetMailDialogViewResponseData } from "@spt-aki/models/eft/dialog/IGetM
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { Dialogue, DialogueInfo, IAkiProfile, IUserDialogInfo, Message } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { MessageType } from "@spt-aki/models/enums/MessageType";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { SaveServer } from "@spt-aki/servers/SaveServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
import { TimeUtil } from "@spt-aki/utils/TimeUtil";
|
||||
export declare class DialogueController {
|
||||
protected logger: ILogger;
|
||||
protected saveServer: SaveServer;
|
||||
protected timeUtil: TimeUtil;
|
||||
protected dialogueHelper: DialogueHelper;
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected hashUtil: HashUtil;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, hashUtil: HashUtil, configServer: ConfigServer);
|
||||
protected dialogueChatBots: IDialogueChatBot[];
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, mailSendService: MailSendService, configServer: ConfigServer, dialogueChatBots: IDialogueChatBot[]);
|
||||
registerChatBot(chatBot: IDialogueChatBot): void;
|
||||
/** Handle onUpdate spt event */
|
||||
update(): void;
|
||||
/**
|
||||
@ -122,13 +115,6 @@ export declare class DialogueController {
|
||||
getAllAttachments(dialogueId: string, sessionId: string): IGetAllAttachmentsResponse;
|
||||
/** client/mail/msg/send */
|
||||
sendMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
protected handleChatWithSPTFriend(sessionId: string, request: ISendMessageRequest): void;
|
||||
protected getSptFriendData(friendId?: string): IUserDialogInfo;
|
||||
/**
|
||||
* Get messages from a specific dialog that have items not expired
|
||||
* @param sessionId Session id
|
||||
|
@ -6,6 +6,7 @@ import { IPmcData } from "@spt-aki/models/eft/common/IPmcData";
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -56,7 +57,7 @@ export declare class MatchController {
|
||||
/** Handle match/group/start_game */
|
||||
joinMatch(info: IJoinMatchRequestData, sessionId: string): IJoinMatchResult;
|
||||
/** Handle client/match/group/status */
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): any;
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): IGetGroupStatusResponse;
|
||||
/**
|
||||
* Handle /client/raid/configuration
|
||||
* @param request Raid config request
|
||||
|
@ -54,8 +54,11 @@ export declare class ProfileController {
|
||||
getCompleteProfile(sessionID: string): IPmcData[];
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
* @param info Client reqeust object
|
||||
* @param sessionID Player id
|
||||
* @returns Profiles _id value
|
||||
*/
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): void;
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): string;
|
||||
/**
|
||||
* Delete a profile
|
||||
* @param sessionID Id of profile to delete
|
||||
|
@ -19,6 +19,7 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { IProcessBuyTradeRequestData } from "@spt-aki/models/eft/trade/IProcessBuyTradeRequestData";
|
||||
@ -69,6 +70,13 @@ export declare class RagfairController {
|
||||
protected ragfairConfig: IRagfairConfig;
|
||||
constructor(logger: ILogger, timeUtil: TimeUtil, httpResponse: HttpResponseUtil, eventOutputHolder: EventOutputHolder, ragfairServer: RagfairServer, ragfairPriceService: RagfairPriceService, databaseServer: DatabaseServer, itemHelper: ItemHelper, saveServer: SaveServer, ragfairSellHelper: RagfairSellHelper, ragfairTaxService: RagfairTaxService, ragfairSortHelper: RagfairSortHelper, ragfairOfferHelper: RagfairOfferHelper, profileHelper: ProfileHelper, paymentService: PaymentService, handbookHelper: HandbookHelper, paymentHelper: PaymentHelper, inventoryHelper: InventoryHelper, traderHelper: TraderHelper, ragfairHelper: RagfairHelper, ragfairOfferService: RagfairOfferService, ragfairRequiredItemsService: RagfairRequiredItemsService, ragfairOfferGenerator: RagfairOfferGenerator, localisationService: LocalisationService, configServer: ConfigServer);
|
||||
getOffers(sessionID: string, searchRequest: ISearchRequestData): IGetOffersResult;
|
||||
/**
|
||||
* Handle client/ragfair/offer/findbyid
|
||||
* @param sessionId Player id
|
||||
* @param request Request data
|
||||
* @returns IRagfairOffer
|
||||
*/
|
||||
getOfferById(sessionId: string, request: IGetRagfairOfferByIdRequest): IRagfairOffer;
|
||||
/**
|
||||
* Get offers for the client based on type of search being performed
|
||||
* @param searchRequest Client search request data
|
||||
@ -111,6 +119,9 @@ export declare class RagfairController {
|
||||
protected setTraderOfferStackSize(offer: IRagfairOffer): void;
|
||||
protected isLinkedSearch(info: ISearchRequestData): boolean;
|
||||
protected isRequiredSearch(info: ISearchRequestData): boolean;
|
||||
/**
|
||||
* Check all profiles and sell player offers / send player money for listing if it sold
|
||||
*/
|
||||
update(): void;
|
||||
/**
|
||||
* Called when creating an offer on flea, fills values in top right corner
|
||||
|
@ -45,6 +45,8 @@ export declare class RagfairOfferGenerator {
|
||||
tpl: string;
|
||||
price: number;
|
||||
}[];
|
||||
/** Internal counter to ensure each offer created has a unique value for its intId property */
|
||||
protected offerCounter: number;
|
||||
constructor(logger: ILogger, jsonUtil: JsonUtil, hashUtil: HashUtil, randomUtil: RandomUtil, timeUtil: TimeUtil, databaseServer: DatabaseServer, ragfairServerHelper: RagfairServerHelper, handbookHelper: HandbookHelper, saveServer: SaveServer, presetHelper: PresetHelper, ragfairAssortGenerator: RagfairAssortGenerator, ragfairOfferService: RagfairOfferService, ragfairPriceService: RagfairPriceService, localisationService: LocalisationService, paymentHelper: PaymentHelper, fenceService: FenceService, itemHelper: ItemHelper, configServer: ConfigServer);
|
||||
/**
|
||||
* Create a flea offer and store it in the Ragfair server offers array
|
||||
|
8
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
8
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ICommandoCommand {
|
||||
getCommandPrefix(): string;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
15
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
export declare class SptCommandoCommands implements ICommandoCommand {
|
||||
protected configServer: ConfigServer;
|
||||
protected sptCommands: ISptCommand[];
|
||||
constructor(configServer: ConfigServer, sptCommands: ISptCommand[]);
|
||||
registerSptCommandoCommand(command: ISptCommand): void;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommandPrefix(): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { PresetHelper } from "@spt-aki/helpers/PresetHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
export declare class GiveSptCommand implements ISptCommand {
|
||||
protected logger: ILogger;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected presetHelper: PresetHelper;
|
||||
protected mailSendService: MailSendService;
|
||||
constructor(logger: ILogger, itemHelper: ItemHelper, hashUtil: HashUtil, jsonUtil: JsonUtil, presetHelper: PresetHelper, mailSendService: MailSendService);
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -0,0 +1,7 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ISptCommand {
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
15
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
export declare class CommandoDialogueChatBot implements IDialogueChatBot {
|
||||
protected logger: ILogger;
|
||||
protected mailSendService: MailSendService;
|
||||
protected commandoCommands: ICommandoCommand[];
|
||||
constructor(logger: ILogger, mailSendService: MailSendService, commandoCommands: ICommandoCommand[]);
|
||||
registerCommandoCommand(commandoCommand: ICommandoCommand): void;
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
6
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
6
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface IDialogueChatBot {
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
25
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
25
TypeScript/12ClassExtensionOverride/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
export declare class SptDialogueChatBot implements IDialogueChatBot {
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, configServer: ConfigServer);
|
||||
getChatBot(): IUserDialogInfo;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -150,6 +150,12 @@ export declare class RagfairOfferHelper {
|
||||
* @returns True = should be shown to player
|
||||
*/
|
||||
isDisplayableOffer(searchRequest: ISearchRequestData, itemsToAdd: string[], traderAssorts: Record<string, ITraderAssort>, offer: IRagfairOffer, pmcProfile: IPmcData): boolean;
|
||||
/**
|
||||
* Does the passed in item have a condition property
|
||||
* @param item Item to check
|
||||
* @returns True if has condition
|
||||
*/
|
||||
protected isConditionItem(item: Item): boolean;
|
||||
/**
|
||||
* Is items quality value within desired range
|
||||
* @param item Item to check quality of
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface ICurrentGroupResponse {
|
||||
squad: any[];
|
||||
squad: ICurrentGroupSquadMember[];
|
||||
}
|
||||
export interface ICurrentGroupSquadMember {
|
||||
_id: string;
|
||||
|
19
TypeScript/12ClassExtensionOverride/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
19
TypeScript/12ClassExtensionOverride/types/models/eft/match/IGetGroupStatusResponse.d.ts
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
import { MemberCategory } from "@spt-aki/models/enums/MemberCategory";
|
||||
export interface IGetGroupStatusResponse {
|
||||
players: IPlayer[];
|
||||
maxPveCountExceeded: boolean;
|
||||
}
|
||||
export interface IPlayer {
|
||||
aid: string;
|
||||
_id: string;
|
||||
lookingGroup: boolean;
|
||||
IsLeader: boolean;
|
||||
IsReady: boolean;
|
||||
Info: ICurrentGroupMemberInfo;
|
||||
}
|
||||
export interface ICurrentGroupMemberInfo {
|
||||
Nickname: string;
|
||||
Side: string;
|
||||
Level: string;
|
||||
MemberCategory: MemberCategory;
|
||||
}
|
3
TypeScript/12ClassExtensionOverride/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
3
TypeScript/12ClassExtensionOverride/types/models/eft/profile/ICreateProfileResponse.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
export interface ICreateProfileResponse {
|
||||
uid: string;
|
||||
}
|
@ -0,0 +1,3 @@
|
||||
export interface IGetRagfairOfferByIdRequest {
|
||||
id: number;
|
||||
}
|
@ -24,4 +24,14 @@ export interface IGameFixes {
|
||||
}
|
||||
export interface IServerFeatures {
|
||||
autoInstallModDependencies: boolean;
|
||||
compressProfile: boolean;
|
||||
chatbotFeatures: IChatbotFeatures;
|
||||
}
|
||||
export interface IChatbotFeatures {
|
||||
sptFriendEnabled: boolean;
|
||||
commandoEnabled: boolean;
|
||||
commandoFeatures: ICommandoFeatures;
|
||||
}
|
||||
export interface ICommandoFeatures {
|
||||
giveCommandEnabled: boolean;
|
||||
}
|
||||
|
@ -98,10 +98,13 @@ export interface IScavRaidTimeConfigSettings {
|
||||
export interface IScavRaidTimeLocationSettings {
|
||||
/** Should loot be reduced by same percent length of raid is reduced by */
|
||||
reduceLootByPercent: boolean;
|
||||
/** Smallest % of container loot that should be spawned */
|
||||
minStaticLootPercent: number;
|
||||
/** Smallest % of loose loot that should be spawned */
|
||||
minDynamicLootPercent: number;
|
||||
/** Chance raid time is reduced */
|
||||
reducedChancePercent: number;
|
||||
/** How much should raid time be reduced - weighted */
|
||||
reductionPercentWeights: Record<string, number>;
|
||||
/** Should bot waves be removed / spawn times be adjusted */
|
||||
adjustWaves: boolean;
|
||||
|
@ -5,6 +5,7 @@ import { LocalisationService } from "@spt-aki/services/LocalisationService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
import { VFS } from "@spt-aki/utils/VFS";
|
||||
import { ConfigServer } from "./ConfigServer";
|
||||
export declare class SaveServer {
|
||||
protected vfs: VFS;
|
||||
protected saveLoadRouters: SaveLoadRouter[];
|
||||
@ -12,11 +13,12 @@ export declare class SaveServer {
|
||||
protected hashUtil: HashUtil;
|
||||
protected localisationService: LocalisationService;
|
||||
protected logger: ILogger;
|
||||
protected configServer: ConfigServer;
|
||||
protected profileFilepath: string;
|
||||
protected profiles: {};
|
||||
protected onBeforeSaveCallbacks: {};
|
||||
protected saveMd5: {};
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger);
|
||||
constructor(vfs: VFS, saveLoadRouters: SaveLoadRouter[], jsonUtil: JsonUtil, hashUtil: HashUtil, localisationService: LocalisationService, logger: ILogger, configServer: ConfigServer);
|
||||
/**
|
||||
* Add callback to occur prior to saving profile changes
|
||||
* @param id Id for save callback
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { ITemplateItem, Props } from "@spt-aki/models/eft/common/tables/ITemplateItem";
|
||||
import { CreateItemResult, LocaleDetails, NewItemDetails, NewItemFromCloneDetails } from "@spt-aki/models/spt/mod/NewItemDetails";
|
||||
import { IDatabaseTables } from "@spt-aki/models/spt/server/IDatabaseTables";
|
||||
@ -10,8 +11,9 @@ export declare class CustomItemService {
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected databaseServer: DatabaseServer;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected tables: IDatabaseTables;
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer);
|
||||
constructor(logger: ILogger, hashUtil: HashUtil, jsonUtil: JsonUtil, databaseServer: DatabaseServer, itemHelper: ItemHelper);
|
||||
/**
|
||||
* Create a new item from a cloned item base
|
||||
* WARNING - If no item id is supplied, an id will be generated, this id will be random every time you add an item and will not be the same on each subsequent server start
|
||||
@ -77,4 +79,11 @@ export declare class CustomItemService {
|
||||
* @param fleaPriceRoubles Price of the new item
|
||||
*/
|
||||
protected addToFleaPriceDb(newItemId: string, fleaPriceRoubles: number): void;
|
||||
/**
|
||||
* Add a custom weapon to PMCs loadout
|
||||
* @param weaponTpl Custom weapon tpl to add to PMCs
|
||||
* @param weaponWeight The weighting for the weapon to be picked vs other weapons
|
||||
* @param weaponSlot The slot the weapon should be added to (e.g. FirstPrimaryWeapon/SecondPrimaryWeapon/Holster)
|
||||
*/
|
||||
addCustomWeaponToPMCs(weaponTpl: string, weaponWeight: number, weaponSlot: string): void;
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ export declare class HttpResponseUtil {
|
||||
* @param errmsg
|
||||
* @returns
|
||||
*/
|
||||
getBody<T>(data: T, err?: number, errmsg?: any): IGetBodyResponseData<T>;
|
||||
getBody<T>(data: T, err?: number, errmsg?: any, sanitize?: boolean): IGetBodyResponseData<T>;
|
||||
getUnclearedBody(data: any, err?: number, errmsg?: any): string;
|
||||
emptyResponse(): IGetBodyResponseData<string>;
|
||||
nullResponse(): INullResponseData;
|
||||
|
@ -86,11 +86,11 @@ export declare class DialogueCallbacks implements OnUpdate {
|
||||
/** Handle client/friend/ignore/set */
|
||||
ignoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
/** Handle client/friend/ignore/remove */
|
||||
unIgnoreFriend(url: string, request: {
|
||||
uid: string;
|
||||
}, sessionID: string): any;
|
||||
}, sessionID: string): INullResponseData;
|
||||
clearMail(url: string, request: IClearMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
removeMail(url: string, request: IRemoveMailMessageRequest, sessionID: string): IGetBodyResponseData<any[]>;
|
||||
onUpdate(timeSinceLastRun: number): Promise<boolean>;
|
||||
|
@ -9,6 +9,7 @@ import { IGameKeepAliveResponse } from "@spt-aki/models/eft/game/IGameKeepAliveR
|
||||
import { IGameLogoutResponseData } from "@spt-aki/models/eft/game/IGameLogoutResponseData";
|
||||
import { IGameStartResponse } from "@spt-aki/models/eft/game/IGameStartResponse";
|
||||
import { IGetRaidTimeRequest } from "@spt-aki/models/eft/game/IGetRaidTimeRequest";
|
||||
import { IGetRaidTimeResponse } from "@spt-aki/models/eft/game/IGetRaidTimeResponse";
|
||||
import { IReportNicknameRequestData } from "@spt-aki/models/eft/game/IReportNicknameRequestData";
|
||||
import { IServerDetails } from "@spt-aki/models/eft/game/IServerDetails";
|
||||
import { IVersionValidateRequestData } from "@spt-aki/models/eft/game/IVersionValidateRequestData";
|
||||
@ -73,5 +74,5 @@ export declare class GameCallbacks implements OnLoad {
|
||||
* Handle singleplayer/settings/getRaidTime
|
||||
* @returns string
|
||||
*/
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): any;
|
||||
getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): IGetRaidTimeResponse;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import { ICancelGroupInviteRequest } from "@spt-aki/models/eft/match/ICancelGrou
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -58,7 +59,7 @@ export declare class MatchCallbacks {
|
||||
* Handle client/match/group/status
|
||||
* @returns
|
||||
*/
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
getGroupStatus(url: string, info: IGetGroupStatusRequestData, sessionID: string): IGetBodyResponseData<IGetGroupStatusResponse>;
|
||||
/** Handle client/match/group/create */
|
||||
createGroup(url: string, info: ICreateGroupRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
/** Handle client/match/group/delete */
|
||||
|
@ -5,6 +5,7 @@ import { IGetBodyResponseData } from "@spt-aki/models/eft/httpResponse/IGetBodyR
|
||||
import { INullResponseData } from "@spt-aki/models/eft/httpResponse/INullResponseData";
|
||||
import { IGetMiniProfileRequestData } from "@spt-aki/models/eft/launcher/IGetMiniProfileRequestData";
|
||||
import { GetProfileStatusResponseData } from "@spt-aki/models/eft/profile/GetProfileStatusResponseData";
|
||||
import { ICreateProfileResponse } from "@spt-aki/models/eft/profile/ICreateProfileResponse";
|
||||
import { IGetProfileSettingsRequest } from "@spt-aki/models/eft/profile/IGetProfileSettingsRequest";
|
||||
import { IProfileChangeNicknameRequestData } from "@spt-aki/models/eft/profile/IProfileChangeNicknameRequestData";
|
||||
import { IProfileChangeVoiceRequestData } from "@spt-aki/models/eft/profile/IProfileChangeVoiceRequestData";
|
||||
@ -23,7 +24,7 @@ export declare class ProfileCallbacks {
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
*/
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<any>;
|
||||
createProfile(url: string, info: IProfileCreateRequestData, sessionID: string): IGetBodyResponseData<ICreateProfileResponse>;
|
||||
/**
|
||||
* Handle client/game/profile/list
|
||||
* Get the complete player profile (scav + pmc character)
|
||||
|
@ -11,6 +11,8 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { IRemoveOfferRequestData } from "@spt-aki/models/eft/ragfair/IRemoveOfferRequestData";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { ISendRagfairReportRequestData } from "@spt-aki/models/eft/ragfair/ISendRagfairReportRequestData";
|
||||
@ -57,4 +59,6 @@ export declare class RagfairCallbacks implements OnLoad, OnUpdate {
|
||||
/** Handle client/reports/ragfair/send */
|
||||
sendReport(url: string, info: ISendRagfairReportRequestData, sessionID: string): INullResponseData;
|
||||
storePlayerOfferTaxAmount(url: string, request: IStorePlayerOfferTaxAmountRequestData, sessionId: string): INullResponseData;
|
||||
/** Handle client/ragfair/offer/findbyid */
|
||||
getFleaOfferById(url: string, request: IGetRagfairOfferByIdRequest, sessionID: string): IGetBodyResponseData<IRagfairOffer>;
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { DialogueHelper } from "@spt-aki/helpers/DialogueHelper";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { IGetAllAttachmentsResponse } from "@spt-aki/models/eft/dialog/IGetAllAttachmentsResponse";
|
||||
import { IGetFriendListDataResponse } from "@spt-aki/models/eft/dialog/IGetFriendListDataResponse";
|
||||
import { IGetMailDialogViewRequestData } from "@spt-aki/models/eft/dialog/IGetMailDialogViewRequestData";
|
||||
@ -7,28 +7,21 @@ import { IGetMailDialogViewResponseData } from "@spt-aki/models/eft/dialog/IGetM
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { Dialogue, DialogueInfo, IAkiProfile, IUserDialogInfo, Message } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { MessageType } from "@spt-aki/models/enums/MessageType";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { SaveServer } from "@spt-aki/servers/SaveServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
import { TimeUtil } from "@spt-aki/utils/TimeUtil";
|
||||
export declare class DialogueController {
|
||||
protected logger: ILogger;
|
||||
protected saveServer: SaveServer;
|
||||
protected timeUtil: TimeUtil;
|
||||
protected dialogueHelper: DialogueHelper;
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected hashUtil: HashUtil;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, hashUtil: HashUtil, configServer: ConfigServer);
|
||||
protected dialogueChatBots: IDialogueChatBot[];
|
||||
constructor(logger: ILogger, saveServer: SaveServer, timeUtil: TimeUtil, dialogueHelper: DialogueHelper, mailSendService: MailSendService, configServer: ConfigServer, dialogueChatBots: IDialogueChatBot[]);
|
||||
registerChatBot(chatBot: IDialogueChatBot): void;
|
||||
/** Handle onUpdate spt event */
|
||||
update(): void;
|
||||
/**
|
||||
@ -122,13 +115,6 @@ export declare class DialogueController {
|
||||
getAllAttachments(dialogueId: string, sessionId: string): IGetAllAttachmentsResponse;
|
||||
/** client/mail/msg/send */
|
||||
sendMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
protected handleChatWithSPTFriend(sessionId: string, request: ISendMessageRequest): void;
|
||||
protected getSptFriendData(friendId?: string): IUserDialogInfo;
|
||||
/**
|
||||
* Get messages from a specific dialog that have items not expired
|
||||
* @param sessionId Session id
|
||||
|
@ -6,6 +6,7 @@ import { IPmcData } from "@spt-aki/models/eft/common/IPmcData";
|
||||
import { ICreateGroupRequestData } from "@spt-aki/models/eft/match/ICreateGroupRequestData";
|
||||
import { IEndOfflineRaidRequestData } from "@spt-aki/models/eft/match/IEndOfflineRaidRequestData";
|
||||
import { IGetGroupStatusRequestData } from "@spt-aki/models/eft/match/IGetGroupStatusRequestData";
|
||||
import { IGetGroupStatusResponse } from "@spt-aki/models/eft/match/IGetGroupStatusResponse";
|
||||
import { IGetProfileRequestData } from "@spt-aki/models/eft/match/IGetProfileRequestData";
|
||||
import { IGetRaidConfigurationRequestData } from "@spt-aki/models/eft/match/IGetRaidConfigurationRequestData";
|
||||
import { IJoinMatchRequestData } from "@spt-aki/models/eft/match/IJoinMatchRequestData";
|
||||
@ -56,7 +57,7 @@ export declare class MatchController {
|
||||
/** Handle match/group/start_game */
|
||||
joinMatch(info: IJoinMatchRequestData, sessionId: string): IJoinMatchResult;
|
||||
/** Handle client/match/group/status */
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): any;
|
||||
getGroupStatus(info: IGetGroupStatusRequestData): IGetGroupStatusResponse;
|
||||
/**
|
||||
* Handle /client/raid/configuration
|
||||
* @param request Raid config request
|
||||
|
@ -54,8 +54,11 @@ export declare class ProfileController {
|
||||
getCompleteProfile(sessionID: string): IPmcData[];
|
||||
/**
|
||||
* Handle client/game/profile/create
|
||||
* @param info Client reqeust object
|
||||
* @param sessionID Player id
|
||||
* @returns Profiles _id value
|
||||
*/
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): void;
|
||||
createProfile(info: IProfileCreateRequestData, sessionID: string): string;
|
||||
/**
|
||||
* Delete a profile
|
||||
* @param sessionID Id of profile to delete
|
||||
|
@ -19,6 +19,7 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe
|
||||
import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult";
|
||||
import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData";
|
||||
import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult";
|
||||
import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest";
|
||||
import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer";
|
||||
import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData";
|
||||
import { IProcessBuyTradeRequestData } from "@spt-aki/models/eft/trade/IProcessBuyTradeRequestData";
|
||||
@ -69,6 +70,13 @@ export declare class RagfairController {
|
||||
protected ragfairConfig: IRagfairConfig;
|
||||
constructor(logger: ILogger, timeUtil: TimeUtil, httpResponse: HttpResponseUtil, eventOutputHolder: EventOutputHolder, ragfairServer: RagfairServer, ragfairPriceService: RagfairPriceService, databaseServer: DatabaseServer, itemHelper: ItemHelper, saveServer: SaveServer, ragfairSellHelper: RagfairSellHelper, ragfairTaxService: RagfairTaxService, ragfairSortHelper: RagfairSortHelper, ragfairOfferHelper: RagfairOfferHelper, profileHelper: ProfileHelper, paymentService: PaymentService, handbookHelper: HandbookHelper, paymentHelper: PaymentHelper, inventoryHelper: InventoryHelper, traderHelper: TraderHelper, ragfairHelper: RagfairHelper, ragfairOfferService: RagfairOfferService, ragfairRequiredItemsService: RagfairRequiredItemsService, ragfairOfferGenerator: RagfairOfferGenerator, localisationService: LocalisationService, configServer: ConfigServer);
|
||||
getOffers(sessionID: string, searchRequest: ISearchRequestData): IGetOffersResult;
|
||||
/**
|
||||
* Handle client/ragfair/offer/findbyid
|
||||
* @param sessionId Player id
|
||||
* @param request Request data
|
||||
* @returns IRagfairOffer
|
||||
*/
|
||||
getOfferById(sessionId: string, request: IGetRagfairOfferByIdRequest): IRagfairOffer;
|
||||
/**
|
||||
* Get offers for the client based on type of search being performed
|
||||
* @param searchRequest Client search request data
|
||||
@ -111,6 +119,9 @@ export declare class RagfairController {
|
||||
protected setTraderOfferStackSize(offer: IRagfairOffer): void;
|
||||
protected isLinkedSearch(info: ISearchRequestData): boolean;
|
||||
protected isRequiredSearch(info: ISearchRequestData): boolean;
|
||||
/**
|
||||
* Check all profiles and sell player offers / send player money for listing if it sold
|
||||
*/
|
||||
update(): void;
|
||||
/**
|
||||
* Called when creating an offer on flea, fills values in top right corner
|
||||
|
@ -45,6 +45,8 @@ export declare class RagfairOfferGenerator {
|
||||
tpl: string;
|
||||
price: number;
|
||||
}[];
|
||||
/** Internal counter to ensure each offer created has a unique value for its intId property */
|
||||
protected offerCounter: number;
|
||||
constructor(logger: ILogger, jsonUtil: JsonUtil, hashUtil: HashUtil, randomUtil: RandomUtil, timeUtil: TimeUtil, databaseServer: DatabaseServer, ragfairServerHelper: RagfairServerHelper, handbookHelper: HandbookHelper, saveServer: SaveServer, presetHelper: PresetHelper, ragfairAssortGenerator: RagfairAssortGenerator, ragfairOfferService: RagfairOfferService, ragfairPriceService: RagfairPriceService, localisationService: LocalisationService, paymentHelper: PaymentHelper, fenceService: FenceService, itemHelper: ItemHelper, configServer: ConfigServer);
|
||||
/**
|
||||
* Create a flea offer and store it in the Ragfair server offers array
|
||||
|
8
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
8
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/ICommandoCommand.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ICommandoCommand {
|
||||
getCommandPrefix(): string;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
15
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommandoCommands.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
export declare class SptCommandoCommands implements ICommandoCommand {
|
||||
protected configServer: ConfigServer;
|
||||
protected sptCommands: ISptCommand[];
|
||||
constructor(configServer: ConfigServer, sptCommands: ISptCommand[]);
|
||||
registerSptCommandoCommand(command: ISptCommand): void;
|
||||
getCommandHelp(command: string): string;
|
||||
getCommandPrefix(): string;
|
||||
getCommands(): Set<string>;
|
||||
handle(command: string, commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
21
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
21
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommands/GiveSptCommand.d.ts
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
import { ISptCommand } from "@spt-aki/helpers/Dialogue/Commando/SptCommands/ISptCommand";
|
||||
import { ItemHelper } from "@spt-aki/helpers/ItemHelper";
|
||||
import { PresetHelper } from "@spt-aki/helpers/PresetHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { HashUtil } from "@spt-aki/utils/HashUtil";
|
||||
import { JsonUtil } from "@spt-aki/utils/JsonUtil";
|
||||
export declare class GiveSptCommand implements ISptCommand {
|
||||
protected logger: ILogger;
|
||||
protected itemHelper: ItemHelper;
|
||||
protected hashUtil: HashUtil;
|
||||
protected jsonUtil: JsonUtil;
|
||||
protected presetHelper: PresetHelper;
|
||||
protected mailSendService: MailSendService;
|
||||
constructor(logger: ILogger, itemHelper: ItemHelper, hashUtil: HashUtil, jsonUtil: JsonUtil, presetHelper: PresetHelper, mailSendService: MailSendService);
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
7
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommands/ISptCommand.d.ts
vendored
Normal file
7
TypeScript/13AddTrader/types/helpers/Dialogue/Commando/SptCommands/ISptCommand.d.ts
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface ISptCommand {
|
||||
getCommand(): string;
|
||||
getCommandHelp(): string;
|
||||
performAction(commandHandler: IUserDialogInfo, sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
15
TypeScript/13AddTrader/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
15
TypeScript/13AddTrader/types/helpers/Dialogue/CommandoDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
import { ICommandoCommand } from "@spt-aki/helpers/Dialogue/Commando/ICommandoCommand";
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ILogger } from "@spt-aki/models/spt/utils/ILogger";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
export declare class CommandoDialogueChatBot implements IDialogueChatBot {
|
||||
protected logger: ILogger;
|
||||
protected mailSendService: MailSendService;
|
||||
protected commandoCommands: ICommandoCommand[];
|
||||
constructor(logger: ILogger, mailSendService: MailSendService, commandoCommands: ICommandoCommand[]);
|
||||
registerCommandoCommand(commandoCommand: ICommandoCommand): void;
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
6
TypeScript/13AddTrader/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
6
TypeScript/13AddTrader/types/helpers/Dialogue/IDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
export interface IDialogueChatBot {
|
||||
getChatBot(): IUserDialogInfo;
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
25
TypeScript/13AddTrader/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
25
TypeScript/13AddTrader/types/helpers/Dialogue/SptDialogueChatBot.d.ts
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
import { IDialogueChatBot } from "@spt-aki/helpers/Dialogue/IDialogueChatBot";
|
||||
import { ProfileHelper } from "@spt-aki/helpers/ProfileHelper";
|
||||
import { ISendMessageRequest } from "@spt-aki/models/eft/dialog/ISendMessageRequest";
|
||||
import { IUserDialogInfo } from "@spt-aki/models/eft/profile/IAkiProfile";
|
||||
import { ICoreConfig } from "@spt-aki/models/spt/config/ICoreConfig";
|
||||
import { ConfigServer } from "@spt-aki/servers/ConfigServer";
|
||||
import { GiftService } from "@spt-aki/services/GiftService";
|
||||
import { MailSendService } from "@spt-aki/services/MailSendService";
|
||||
import { RandomUtil } from "@spt-aki/utils/RandomUtil";
|
||||
export declare class SptDialogueChatBot implements IDialogueChatBot {
|
||||
protected profileHelper: ProfileHelper;
|
||||
protected randomUtil: RandomUtil;
|
||||
protected mailSendService: MailSendService;
|
||||
protected giftService: GiftService;
|
||||
protected configServer: ConfigServer;
|
||||
protected coreConfig: ICoreConfig;
|
||||
constructor(profileHelper: ProfileHelper, randomUtil: RandomUtil, mailSendService: MailSendService, giftService: GiftService, configServer: ConfigServer);
|
||||
getChatBot(): IUserDialogInfo;
|
||||
/**
|
||||
* Send responses back to player when they communicate with SPT friend on friends list
|
||||
* @param sessionId Session Id
|
||||
* @param request send message request
|
||||
*/
|
||||
handleMessage(sessionId: string, request: ISendMessageRequest): string;
|
||||
}
|
@ -150,6 +150,12 @@ export declare class RagfairOfferHelper {
|
||||
* @returns True = should be shown to player
|
||||
*/
|
||||
isDisplayableOffer(searchRequest: ISearchRequestData, itemsToAdd: string[], traderAssorts: Record<string, ITraderAssort>, offer: IRagfairOffer, pmcProfile: IPmcData): boolean;
|
||||
/**
|
||||
* Does the passed in item have a condition property
|
||||
* @param item Item to check
|
||||
* @returns True if has condition
|
||||
*/
|
||||
protected isConditionItem(item: Item): boolean;
|
||||
/**
|
||||
* Is items quality value within desired range
|
||||
* @param item Item to check quality of
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user