Move hard coded gameversion/account type values into bot config
This commit is contained in:
parent
5ca2b3e890
commit
ea270a95a5
@ -993,6 +993,18 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"pmc": {
|
"pmc": {
|
||||||
|
"gameVersionWeight": {
|
||||||
|
"standard": 5,
|
||||||
|
"left_behind": 1,
|
||||||
|
"prepare_for_escape": 1,
|
||||||
|
"edge_of_darkness": 3
|
||||||
|
},
|
||||||
|
"accountTypeWeight": {
|
||||||
|
0: 15,
|
||||||
|
1: 1,
|
||||||
|
256: 3,
|
||||||
|
512: 3
|
||||||
|
},
|
||||||
"vestLoot": {
|
"vestLoot": {
|
||||||
"whitelist": [
|
"whitelist": [
|
||||||
"5485a8684bdc2da71d8b4567",
|
"5485a8684bdc2da71d8b4567",
|
||||||
|
@ -426,7 +426,7 @@ export class BotGenerator
|
|||||||
*/
|
*/
|
||||||
protected getRandomisedGameVersionAndCategory(botInfo: Info): void
|
protected getRandomisedGameVersionAndCategory(botInfo: Info): void
|
||||||
{
|
{
|
||||||
if (botInfo.Nickname === "Nikita")
|
if (botInfo.Nickname.toLowerCase() === "nikita")
|
||||||
{
|
{
|
||||||
botInfo.GameVersion = "edge_of_darkness";
|
botInfo.GameVersion = "edge_of_darkness";
|
||||||
botInfo.AccountType = MemberCategory.DEVELOPER;
|
botInfo.AccountType = MemberCategory.DEVELOPER;
|
||||||
@ -434,10 +434,8 @@ export class BotGenerator
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const gameVersions = ["standard", "standard", "left_behind", "prepare_for_escape", "edge_of_darkness"];
|
botInfo.GameVersion = this.weightedRandomHelper.getWeightedValue(this.botConfig.pmc.gameVersionWeight);
|
||||||
const accountTypes = [MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEFAULT,MemberCategory.DEVELOPER, MemberCategory.SHERPA,MemberCategory.SHERPA,MemberCategory.SHERPA,MemberCategory.EMISSARY, MemberCategory.EMISSARY, MemberCategory.EMISSARY]; // 0 = normal, 1 = dev, 256 = sherpa, 512 = emissary
|
botInfo.AccountType = Number.parseInt(this.weightedRandomHelper.getWeightedValue(this.botConfig.pmc.accountTypeWeight));
|
||||||
botInfo.GameVersion = this.randomUtil.getArrayValue(gameVersions);
|
|
||||||
botInfo.AccountType = this.randomUtil.getArrayValue(accountTypes);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1,9 +1,17 @@
|
|||||||
|
import { MemberCategory } from "../../../models/enums/MemberCategory";
|
||||||
import { MinMax } from "../../common/MinMax";
|
import { MinMax } from "../../common/MinMax";
|
||||||
|
|
||||||
export interface IPmcConfig
|
export interface IPmcConfig
|
||||||
{
|
{
|
||||||
|
/** What game version should the PMC have */
|
||||||
|
gameVersionWeight: Record<string, number>
|
||||||
|
/** What account type should the PMC have */
|
||||||
|
accountTypeWeight: Record<MemberCategory, number>
|
||||||
|
/** Global whitelist/blacklist of vest loot for PMCs */
|
||||||
vestLoot: SlotLootSettings
|
vestLoot: SlotLootSettings
|
||||||
|
/** Global whitelist/blacklist of pocket loot for PMCs */
|
||||||
pocketLoot: SlotLootSettings
|
pocketLoot: SlotLootSettings
|
||||||
|
/** Global whitelist/blacklist of backpack loot for PMCs */
|
||||||
backpackLoot: SlotLootSettings
|
backpackLoot: SlotLootSettings
|
||||||
dynamicLoot: DynamicLoot
|
dynamicLoot: DynamicLoot
|
||||||
useDifficultyOverride: boolean
|
useDifficultyOverride: boolean
|
||||||
|
Loading…
Reference in New Issue
Block a user