fix deimos special handling
All checks were successful
Build / build (pull_request) Successful in 40s
Build / build (push) Successful in 1m26s

This commit is contained in:
Sainan 2025-04-11 01:04:51 +02:00
parent d2585f5b09
commit 536013c414

View File

@ -324,9 +324,10 @@ export const getWorldState = (buildLabel?: string): IWorldState => {
syndicateInfo.Seed = bountyCycle; syndicateInfo.Seed = bountyCycle;
logger.debug(`refreshing jobs for ${syndicateInfo.Tag}`); logger.debug(`refreshing jobs for ${syndicateInfo.Tag}`);
const rng = new CRng(bountyCycle); const rng = new CRng(bountyCycle);
const table = String.fromCharCode(65 + ((bountyCycle - 1) % 3)); const table = String.fromCharCode(65 + (bountyCycle % 3));
const vaultTable = String.fromCharCode(65 + ((bountyCycle - 2) % 3)); const vaultTable = String.fromCharCode(65 + ((bountyCycle + 1) % 3));
const endlessTable = String.fromCharCode(65 + ((bountyCycle - 3) % 3)); const deimosDTable = String.fromCharCode(65 + (bountyCycle % 2));
//console.log({ bountyCycleStart, bountyCycleEnd, table, vaultTable, deimosDTable });
for (const jobInfo of syndicateInfo.Jobs) { for (const jobInfo of syndicateInfo.Jobs) {
if (jobInfo.jobType) { if (jobInfo.jobType) {
let found = false; let found = false;
@ -342,11 +343,11 @@ export const getWorldState = (buildLabel?: string): IWorldState => {
logger.warn(`no job set found for type ${jobInfo.jobType}`); logger.warn(`no job set found for type ${jobInfo.jobType}`);
} }
} }
if (jobInfo.endless) { if (jobInfo.endless || jobInfo.isVault) {
jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${endlessTable}Rewards`);
} else if (jobInfo.isVault) {
jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${vaultTable}Rewards`); jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${vaultTable}Rewards`);
} else { } else if (jobInfo.rewards.startsWith("/Lotus/Types/Game/MissionDecks/DeimosMissionRewards/TierD")) {
jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${deimosDTable}Rewards`);
} else if (!jobInfo.rewards.startsWith("/Lotus/Types/Game/MissionDecks/DeimosMissionRewards/TierE")) {
jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${table}Rewards`); jobInfo.rewards = jobInfo.rewards.replace(/Table.Rewards/, `Table${table}Rewards`);
} }
} }