Add endpoint to configure trailtor scavs
This commit is contained in:
parent
f2bcbbf8ab
commit
ff1e80e302
@ -36,5 +36,6 @@
|
||||
"coopExtractBaseStandingGain": 0.25,
|
||||
"scavExtractGain": 0.01,
|
||||
"pmcKillProbabilityForScavGain": 0.2,
|
||||
"keepFiRSecureContainerOnDeath": false
|
||||
"keepFiRSecureContainerOnDeath": false,
|
||||
"playerScavHostileChancePercent": 20
|
||||
}
|
||||
|
@ -110,4 +110,9 @@ export class InraidCallbacks
|
||||
this.inraidController.itemDelivery(sessionId, request.traderId, request.items);
|
||||
return this.httpResponse.nullResponse();
|
||||
}
|
||||
|
||||
public getTraitorScavHostileChance(url: string, info: IEmptyRequestData, sessionId: string): string
|
||||
{
|
||||
return this.httpResponse.noBody(this.inraidController.getTraitorScavHostileChance(url, sessionId));
|
||||
}
|
||||
}
|
||||
|
@ -565,4 +565,9 @@ export class InraidController
|
||||
messageStoreTime,
|
||||
);
|
||||
}
|
||||
|
||||
public getTraitorScavHostileChance(url: string, sessionID: string): number
|
||||
{
|
||||
return this.inRaidConfig.playerScavHostileChancePercent;
|
||||
}
|
||||
}
|
||||
|
@ -22,6 +22,8 @@ export interface IInRaidConfig extends IBaseConfig
|
||||
pmcKillProbabilityForScavGain: number;
|
||||
/** On death should items in your secure keep their Find in raid status regardless of how you finished the raid */
|
||||
keepFiRSecureContainerOnDeath: boolean;
|
||||
/** Percentage chance a player scav hot is hostile to the player when scavving */
|
||||
playerScavHostileChancePercent: number;
|
||||
}
|
||||
|
||||
export interface RaidMenuSettings
|
||||
|
@ -55,6 +55,13 @@ export class InraidStaticRouter extends StaticRouter
|
||||
return this.inraidCallbacks.itemDelivery(url, info, sessionID);
|
||||
},
|
||||
),
|
||||
new RouteAction(
|
||||
"/singleplayer/scav/traitorscavhostile",
|
||||
(url: string, info: any, sessionID: string, output: string): any =>
|
||||
{
|
||||
return this.inraidCallbacks.getTraitorScavHostileChance(url, info, sessionID);
|
||||
},
|
||||
),
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user