diff --git a/build/tradable.mjs b/build/tradable.mjs index 70b9499bf..2ab2699dc 100644 --- a/build/tradable.mjs +++ b/build/tradable.mjs @@ -10,6 +10,22 @@ const builtUntradable = [ 'Launcher', 'Sniper', ]; +/** + * Gate built Prime items (Warframes, weapons) from being marked tradable. + * Built Prime items are not directly tradable -- only their individual + * components/parts are (e.g. Loki Prime Blueprint). Components get their + * own tradable flag set independently during parsing. + * + * To determine if a Prime set is tradable, check item.components for + * parts with tradable: true. + * + * Item-specific tradability overrides live in config/overrides.json + * (keyed by uniqueName) and are applied by parser.mjs applyOverrides() + * after this check runs. + * + * @param {module:warframe-items.Item} item Item to check + * @returns {boolean} + */ const tradableConditions = (item) => !(builtUntradable.includes(item.type) && item.name.match(/Prime/gi)); const tradableArcanes = [