Added handling of Railjack Abandoned Caches
Some checks failed
Build / build (pull_request) Failing after 56s

Including warning
This commit is contained in:
VampireKitten 2025-08-12 16:00:09 +02:00
parent 9cc0c76ef5
commit 52960da3e4
2 changed files with 32 additions and 0 deletions

View File

@ -1936,6 +1936,36 @@ function getRandomMissionDrops(
}
});
// Railjack Abandoned Cache Rewards, Rotation A (Mandatory Objectives)
if (RewardInfo.POICompletions) {
if(region.cacheRewardManifest){
const deck = ExportRewards[region.cacheRewardManifest];
for (let cache = 0; cache != RewardInfo.POICompletions; ++cache) {
const drop = getRandomRewardByChance(deck[0]);
if (drop) {
drops.push({ StoreItem: drop.type, ItemCount: drop.itemCount, FromEnemyCache: true });
}
}
} else {
logger.error(`POI completed, but there was no cache reward manifest at ${RewardInfo.node}`);
}
}
// Railjack Abandoned Cache Rewards, Rotation B (Optional Objectives)
if (RewardInfo.LootDungeonCompletions) {
if(region.cacheRewardManifest){
const deck = ExportRewards[region.cacheRewardManifest];
for (let cache = 0; cache != RewardInfo.LootDungeonCompletions; ++cache) {
const drop = getRandomRewardByChance(deck[1]);
if (drop) {
drops.push({ StoreItem: drop.type, ItemCount: drop.itemCount, FromEnemyCache: true });
}
}
} else {
logger.error(`Loot dungeon completed, but there was no cache reward manifest at ${RewardInfo.node}`);
}
}
if (region.cacheRewardManifest && RewardInfo.EnemyCachesFound) {
const deck = ExportRewards[region.cacheRewardManifest];
for (let rotation = 0; rotation != RewardInfo.EnemyCachesFound; ++rotation) {

View File

@ -187,6 +187,8 @@ export interface IRewardInfo {
rewardQualifications?: string; // did a Survival for 5 minutes and this was "1"
rewardTierOverrides?: number[]; // Disruption
PurgatoryRewardQualifications?: string;
POICompletions?: number;
LootDungeonCompletions?: number;
rewardSeed?: number | bigint;
periodicMissionTag?: string;
T?: number; // Duviri