diff --git a/src/resources.ts b/src/resources.ts index a68d217d..c7f1da17 100644 --- a/src/resources.ts +++ b/src/resources.ts @@ -320,6 +320,12 @@ export const otherResources: Resource[] = [ [], get("instant_saveHeartstoneKill", false) ? 5 : 0, ), + new Resource( + "instant_saveSaberForceUses", + (n) => `Save ${n}/5 Cosplay Saber Force Uses`, + [], + get("instant_saveSaberForceUses", false) ? 5 : 0, + ), ]; const allResources = [ diff --git a/src/tasks/boozedrop.ts b/src/tasks/boozedrop.ts index 991c0325..3b4273fb 100644 --- a/src/tasks/boozedrop.ts +++ b/src/tasks/boozedrop.ts @@ -238,7 +238,10 @@ export const BoozeDropQuest: Quest = { ? $item`Daylight Shavings Helmet` : undefined, back: $item`vampyric cloake`, - weapon: $item`Fourth of May Cosplay Saber`, + weapon: + get("_saberForceUses") < 5 - get("instant_saveSaberForceUses", 0) + ? $item`Fourth of May Cosplay Saber` + : undefined, offhand: have($skill`Double-Fisted Skull Smashing`) ? $item`industrial fire extinguisher` : undefined, @@ -251,7 +254,10 @@ export const BoozeDropQuest: Quest = { Macro.trySkill($skill`Bowl Straight Up`) .trySkill($skill`Become a Bat`) .trySkill($skill`Fire Extinguisher: Polar Vortex`) - .trySkill($skill`Use the Force`) + .externalIf( + get("_saberForceUses") < 5 - get("instant_saveSaberForceUses", 0), + Macro.trySkill($skill`Use the Force`), + ) .default(), ), limit: { tries: 5 }, diff --git a/src/tasks/familiarweight.ts b/src/tasks/familiarweight.ts index 037d677b..80708563 100644 --- a/src/tasks/familiarweight.ts +++ b/src/tasks/familiarweight.ts @@ -91,7 +91,7 @@ export const FamiliarWeightQuest: Quest = { acquiredOrExcluded($effect`Meteor Showered`) || !have($item`Fourth of May Cosplay Saber`) || !have($skill`Meteor Lore`) || - get("_saberForceUses") >= 5, + get("_saberForceUses") >= 5 - get("instant_saveSaberForceUses", 0), do: $location`The Dire Warren`, combat: new CombatStrategy().macro( Macro.trySkill($skill`Meteor Shower`) diff --git a/src/tasks/hotres.ts b/src/tasks/hotres.ts index 81632a01..7ca95e6d 100644 --- a/src/tasks/hotres.ts +++ b/src/tasks/hotres.ts @@ -94,7 +94,10 @@ export const HotResQuest: Quest = { outfit: () => ({ back: $item`vampyric cloake`, shirt: $item`Jurassic Parka`, - weapon: $item`Fourth of May Cosplay Saber`, + weapon: + get("_saberForceUses") < 5 - get("instant_saveSaberForceUses", 0) + ? $item`Fourth of May Cosplay Saber` + : undefined, offhand: have($skill`Double-Fisted Skull Smashing`) ? $item`industrial fire extinguisher` : have($effect`Everything Looks Yellow`) @@ -108,7 +111,10 @@ export const HotResQuest: Quest = { combat: new CombatStrategy().macro( Macro.trySkill($skill`Become a Cloud of Mist`) .trySkill($skill`Fire Extinguisher: Foam Yourself`) - .trySkill($skill`Use the Force`) + .externalIf( + get("_saberForceUses") < 5 - get("instant_saveSaberForceUses", 0), + Macro.trySkill($skill`Use the Force`), + ) .trySkill($skill`Shocking Lick`) .if_( "!haseffect Everything Looks Yellow", @@ -130,7 +136,7 @@ export const HotResQuest: Quest = { completed: () => acquiredOrExcluded($effect`Fireproof Foam Suit`) || !have($item`Fourth of May Cosplay Saber`) || - get("_saberForceUses") >= 5 || + get("_saberForceUses") >= 5 - get("instant_saveSaberForceUses", 0) || !have($item`industrial fire extinguisher`) || !have($skill`Double-Fisted Skull Smashing`), do: $location`The Dire Warren`, diff --git a/src/tasks/spelldamage.ts b/src/tasks/spelldamage.ts index 1bd98ac6..ec544a72 100644 --- a/src/tasks/spelldamage.ts +++ b/src/tasks/spelldamage.ts @@ -207,7 +207,7 @@ export const SpellDamageQuest: Quest = { acquiredOrExcluded($effect`Meteor Showered`) || !have($item`Fourth of May Cosplay Saber`) || !have($skill`Meteor Lore`) || - get("_saberForceUses") >= 5, + get("_saberForceUses") >= 5 - get("instant_saveSaberForceUses", 0), do: $location`The Dire Warren`, combat: new CombatStrategy().macro( Macro.trySkill($skill`Meteor Shower`) diff --git a/src/tasks/weapondamage.ts b/src/tasks/weapondamage.ts index 344a5cd2..c28f5578 100644 --- a/src/tasks/weapondamage.ts +++ b/src/tasks/weapondamage.ts @@ -185,7 +185,7 @@ export const WeaponDamageQuest: Quest = { acquiredOrExcluded($effect`Meteor Showered`) || !have($item`Fourth of May Cosplay Saber`) || !have($skill`Meteor Lore`) || - get("_saberForceUses") >= 5, + get("_saberForceUses") >= 5 - get("instant_saveSaberForceUses", 0), do: attemptKFH ? powerlevelingLocation() : $location`The Dire Warren`, combat: new CombatStrategy().macro( Macro.trySkill($skill`Meteor Shower`)