Add property to ragfair blacklist to toggle removal of damaged
ammo packs
This commit is contained in:
parent
263e5c8dd5
commit
343be66806
@ -145,6 +145,7 @@
|
|||||||
],
|
],
|
||||||
"removeSeasonalItemsWhenNotInEvent": true,
|
"removeSeasonalItemsWhenNotInEvent": true,
|
||||||
"blacklist": {
|
"blacklist": {
|
||||||
|
"damagedAmmoPacks": true,
|
||||||
"custom": [],
|
"custom": [],
|
||||||
"enableBsgList": true,
|
"enableBsgList": true,
|
||||||
"enableQuestList": true,
|
"enableQuestList": true,
|
||||||
|
@ -2,6 +2,7 @@ import { inject, injectable } from "tsyringe";
|
|||||||
|
|
||||||
import { Item } from "../models/eft/common/tables/IItem";
|
import { Item } from "../models/eft/common/tables/IItem";
|
||||||
import { ITemplateItem } from "../models/eft/common/tables/ITemplateItem";
|
import { ITemplateItem } from "../models/eft/common/tables/ITemplateItem";
|
||||||
|
import { BaseClasses } from "../models/enums/BaseClasses";
|
||||||
import { ConfigTypes } from "../models/enums/ConfigTypes";
|
import { ConfigTypes } from "../models/enums/ConfigTypes";
|
||||||
import { MemberCategory } from "../models/enums/MemberCategory";
|
import { MemberCategory } from "../models/enums/MemberCategory";
|
||||||
import { MessageType } from "../models/enums/MessageType";
|
import { MessageType } from "../models/enums/MessageType";
|
||||||
@ -87,6 +88,12 @@ export class RagfairServerHelper
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Don't include damaged ammo packs
|
||||||
|
if (this.ragfairConfig.dynamic.blacklist.damagedAmmoPacks && itemDetails[1]._parent === BaseClasses.AMMO_BOX && itemDetails[1]._name.includes("_damaged"))
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -129,6 +129,8 @@ export interface Condition
|
|||||||
|
|
||||||
export interface Blacklist
|
export interface Blacklist
|
||||||
{
|
{
|
||||||
|
/** Damaged ammo packs */
|
||||||
|
damagedAmmoPacks: boolean
|
||||||
/** Custom blacklist for item Tpls */
|
/** Custom blacklist for item Tpls */
|
||||||
custom: string[]
|
custom: string[]
|
||||||
/** BSG blacklist a large number of items from flea, true = use blacklist */
|
/** BSG blacklist a large number of items from flea, true = use blacklist */
|
||||||
|
Loading…
Reference in New Issue
Block a user