From c46e4daa1de9aebbcf041de8c1166625a33eb748 Mon Sep 17 00:00:00 2001 From: pajlada Date: Sun, 24 Sep 2023 11:23:46 +0200 Subject: [PATCH] Olaf's Quest: Minor polish (#1279) * fix: Add the "Pick up the dropped key" as a substep to the "Kill skeleton" step This means the side menu doesn't flip out when being prompted to loot the key * feat: Highlight the barrels in your inventory * chore: Run Reformat code on the quest file --- .../helpers/quests/olafsquest/OlafsQuest.java | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/questhelper/helpers/quests/olafsquest/OlafsQuest.java b/src/main/java/com/questhelper/helpers/quests/olafsquest/OlafsQuest.java index 31984162f8..b2863681d9 100644 --- a/src/main/java/com/questhelper/helpers/quests/olafsquest/OlafsQuest.java +++ b/src/main/java/com/questhelper/helpers/quests/olafsquest/OlafsQuest.java @@ -76,7 +76,7 @@ public class OlafsQuest extends BasicQuestHelper triangleKey, circleKey, starKey; //Items Recommended - ItemRequirement prayerPotions, food, combatGear; + ItemRequirement prayerPotions, food, combatGear; Requirement givenIngridCarving, inFirstArea, inSecondArea, inThirdArea, keyNearby, puzzleOpen, has2Barrels6Ropes, hasBarrel3Ropes, placedBarrel1, placedBarrel2, keyInterfaceOpen, ulfricNearby, killedUlfric, tenFreeSlots; @@ -148,10 +148,10 @@ public void setupRequirements() { combatGear = new ItemRequirement("Combat gear", -1, -1).isNotConsumed(); combatGear.setDisplayItemId(BankSlotIcons.getCombatGear()); - + food = new ItemRequirement("Food", ItemCollections.GOOD_EATING_FOOD, -1); food.setUrlSuffix("Food"); - + prayerPotions = new ItemRequirement("Prayer potions", ItemCollections.PRAYER_POTIONS, -1); axe = new ItemRequirement("Any axe", ItemCollections.AXES).isNotConsumed(); @@ -232,11 +232,12 @@ public void setupSteps() talkToOlafAfterPlanks.addDialogStep("Alright, here, have some food. Now give me the map."); digHole = new DigStep(this, new WorldPoint(2748, 3732, 0), "Dig next to the Windswept Tree."); + pickUpKey = new ItemStep(this, "Pick up the dropped key.", key); + killSkeleton = new NpcStep(this, NpcID.SKELETON_FREMENNIK, new WorldPoint(2727, 10141, 0), "Go deeper into the caverns and kill a Skeleton Fremennik for a key.", true); killSkeleton.addAlternateNpcs(NpcID.SKELETON_FREMENNIK_4492, NpcID.SKELETON_FREMENNIK_4493, NpcID.SKELETON_FREMENNIK_4494, NpcID.SKELETON_FREMENNIK_4495, NpcID.SKELETON_FREMENNIK_4496, NpcID.SKELETON_FREMENNIK_4497, NpcID.SKELETON_FREMENNIK_4498, NpcID.SKELETON_FREMENNIK_4499); - - pickUpKey = new ItemStep(this, "Pick up the dropped key.", key); + killSkeleton.addSubSteps(pickUpKey); searchPainting = new ObjectStep(this, ObjectID.PICTURE_WALL, new WorldPoint(2707, 10147, 0), "Search the picture wall in the north room."); @@ -246,9 +247,9 @@ public void setupSteps() pickUpItems2 = new DetailedQuestStep(this, "Pick up 1 rotten barrels and 3 ropes from around the room.", rottenBarrel, ropes3); pickUpItems.addSubSteps(pickUpItems2); - useBarrel = new ObjectStep(this, ObjectID.WALKWAY, new WorldPoint(2722, 10168, 0), "WALK onto the walkway to the east, and use a barrel on it to repair it.", rottenBarrel, ropes3); + useBarrel = new ObjectStep(this, ObjectID.WALKWAY, new WorldPoint(2722, 10168, 0), "WALK onto the walkway to the east, and use a barrel on it to repair it.", rottenBarrel.highlighted(), ropes3); useBarrel.addIcon(ItemID.ROTTEN_BARREL_11045); - useBarrel2 = new ObjectStep(this, ObjectID.WALKWAY_23214, new WorldPoint(2724, 10168, 0), "WALK on the walkway and repair the next hole in it.", rottenBarrel, ropes3); + useBarrel2 = new ObjectStep(this, ObjectID.WALKWAY_23214, new WorldPoint(2724, 10168, 0), "WALK on the walkway and repair the next hole in it.", rottenBarrel.highlighted(), ropes3); useBarrel2.addIcon(ItemID.ROTTEN_BARREL_11045); openGate = new ObjectStep(this, ObjectID.GATE_23216, new WorldPoint(2725, 10168, 0), "Open the gate on the walkway, clicking the key hole which matches your key.", key);