handle giveKeyChainTriggeredMessage with ChainStage = 0
All checks were successful
Build / build (pull_request) Successful in 1m37s
All checks were successful
Build / build (pull_request) Successful in 1m37s
This commit is contained in:
parent
ef1922146a
commit
37c2da0f8e
@ -83,10 +83,16 @@ export const updateQuestStage = (
|
||||
`Quest stage index mismatch: stage is ${ChainStage} but array size is ${quest.Progress.length}`
|
||||
);
|
||||
}
|
||||
const questStage = quest.Progress[ChainStage]; // guaranteed in-bounds now
|
||||
// Note that the client may use index 0 as well, e.g. for rising tide's initial inbox message. 'm' is not tracked for it.
|
||||
if (ChainStage >= 0) {
|
||||
const questStage = quest.Progress[ChainStage]; // guaranteed in-bounds now
|
||||
|
||||
for (const [key, value] of Object.entries(questStageUpdate) as [keyof IQuestStage, number | boolean | any[]][]) {
|
||||
(questStage[key] as any) = value;
|
||||
for (const [key, value] of Object.entries(questStageUpdate) as [
|
||||
keyof IQuestStage,
|
||||
number | boolean | any[]
|
||||
][]) {
|
||||
(questStage[key] as any) = value;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user