Skip to content

Commit

Permalink
Fix Hellfire bow dupe bug
Browse files Browse the repository at this point in the history
  • Loading branch information
themrrobert committed May 13, 2024
1 parent ef60b96 commit 304d1e1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/tasks/minions/monsterActivity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -258,12 +258,13 @@ export const monsterTask: MinionTask = {
});

let reEquipedItems = false;
if (!user.bank.has(calc.lostItems)) {
const itemsToReplace = new Bank().add(calc.lostItems).add(calc.gearThatBroke);
if (!user.bank.has(itemsToReplace)) {
await user.update({
gear_wildy: calc.newGear as Prisma.InputJsonObject
});
} else {
await user.transactItems({ itemsToRemove: calc.lostItems });
await user.transactItems({ itemsToRemove: itemsToReplace });
reEquipedItems = true;
}

Expand Down

0 comments on commit 304d1e1

Please sign in to comment.