Skip to main content
The Deno 2 Release Candidate is here
Learn more
class MatchController
import { MatchController } from "https://deno.land/x/sptaki@1.2.0/controllers/MatchController.d.ts";

Constructors

new
MatchController(
logger: ILogger,
saveServer: SaveServer,
timeUtil: TimeUtil,
randomUtil: RandomUtil,
hashUtil: HashUtil,
profileHelper: ProfileHelper,
matchLocationService: MatchLocationService,
traderHelper: TraderHelper,
botLootCacheService: BotLootCacheService,
configServer: ConfigServer,
profileSnapshotService: ProfileSnapshotService,
botGenerationCacheService: BotGenerationCacheService,
mailSendService: MailSendService,
lootGenerator: LootGenerator,
applicationContext: ApplicationContext,
)

Properties

protected
applicationContext: ApplicationContext
protected
botGenerationCacheService: BotGenerationCacheService
protected
botLootCacheService: BotLootCacheService
protected
configServer: ConfigServer
protected
hashUtil: HashUtil
protected
inRaidConfig: IInRaidConfig
protected
logger: ILogger
protected
lootGenerator: LootGenerator
protected
mailSendService: MailSendService
protected
matchConfig: IMatchConfig
protected
matchLocationService: MatchLocationService
protected
pmcConfig: IPmcConfig
protected
profileHelper: ProfileHelper
protected
profileSnapshotService: ProfileSnapshotService
protected
randomUtil: RandomUtil
protected
saveServer: SaveServer
protected
timeUtil: TimeUtil
protected
traderConfig: ITraderConfig
protected
traderHelper: TraderHelper

Methods

protected
convertDifficultyDropdownIntoBotDifficulty(botDifficulty: string): string

Convert a difficulty value from pre-raid screen to a bot difficulty

protected
extractWasViaCar(extractName: string): boolean

Was extract by car

protected
extractWasViaCoop(extractName: string): boolean

Did player take a COOP extract

protected
getFenceStandingAfterExtract(
pmcData: IPmcData,
baseGain: number,
extractCount: number,
): number

Get the fence rep gain from using a car or coop extract

protected
handleCarExtract(
extractName: string,
pmcData: IPmcData,
sessionId: string,
): void

Handle when a player extracts using a car - Add rep to fence

protected
handleCoopExtract(
sessionId: string,
pmcData: IPmcData,
extractName: string,
): void

Handle when a player extracts using a coop extract - add rep to fence

protected
sendCoopTakenFenceMessage(sessionId: string): void
deleteGroup(info: any): void

Handle client/match/group/delete

endOfflineRaid(info: IEndOfflineRaidRequestData, sessionId: string): void

Handle client/match/offline/end

getEnabled(): boolean

Handle client/match/group/status

Handle match/group/start_game

startOfflineRaid(request: IGetRaidConfigurationRequestData, sessionID: string): void

Handle /client/raid/configuration