Skip to content

Commit

Permalink
Add ShadowDuat and HiddenDuat story scripts; enhance CoreShadowofDoom…
Browse files Browse the repository at this point in the history
… with new methods
  • Loading branch information
PUNK3DAF committed Nov 9, 2024
1 parent 83c1eda commit 1aeb074
Show file tree
Hide file tree
Showing 4 changed files with 324 additions and 0 deletions.
101 changes: 101 additions & 0 deletions Seasonal/BlackFriday/HiddenDuatMerge.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
/*
name: HiddenDuat Merge
description: This bot will farm the items belonging to the selected mode for the HiddenDuat Merge [2501] in /hiddenduat
tags: hiddenduat, merge, hiddenduat, apophis, medjai, bangs, morph, horned, dark, umbral, scythe, aaru, bow
*/
//cs_include Scripts/CoreBots.cs
//cs_include Scripts/CoreFarms.cs
//cs_include Scripts/CoreStory.cs
//cs_include Scripts/CoreAdvanced.cs
//cs_include Scripts/Seasonal\BlackFriday\ShadowofDoom\CoreShadowofDoom.cs
using Skua.Core.Interfaces;
using Skua.Core.Models.Items;
using Skua.Core.Options;

public class HiddenDuatMerge
{
private IScriptInterface Bot => IScriptInterface.Instance;
private CoreBots Core => CoreBots.Instance;
private CoreFarms Farm = new();
private CoreAdvanced Adv = new();
private static CoreAdvanced sAdv = new();
private CoreShadowofDoom CSoD = new();

public List<IOption> Generic = sAdv.MergeOptions;
public string[] MultiOptions = { "Generic", "Select" };
public string OptionsStorage = sAdv.OptionsStorage;
// [Can Change] This should only be changed by the author.
// If true, it will not stop the script if the default case triggers and the user chose to only get mats
private bool dontStopMissingIng = false;

public void ScriptMain(IScriptInterface Bot)
{
Core.BankingBlackList.AddRange(new[] { "Crown of Chaos" });
Core.SetOptions();

BuyAllMerge();
Core.SetOptions(false);
}

public void BuyAllMerge(string? buyOnlyThis = null, mergeOptionsEnum? buyMode = null)
{
CSoD.HiddenDuat();

//Only edit the map and shopID here
Adv.StartBuyAllMerge("hiddenduat", 2501, findIngredients, buyOnlyThis, buyMode: buyMode);

#region Dont edit this part
void findIngredients()
{
ItemBase req = Adv.externalItem;
int quant = Adv.externalQuant;
int currentQuant = req.Temp ? Bot.TempInv.GetQuantity(req.Name) : Bot.Inventory.GetQuantity(req.Name);
if (req == null)
{
Core.Logger("req is NULL");
return;
}

switch (req.Name)
{
default:
bool shouldStop = !Adv.matsOnly || !dontStopMissingIng;
Core.Logger($"The bot hasn't been taught how to get {req.Name}." + (shouldStop ? " Please report the issue." : " Skipping"), messageBox: shouldStop, stopBot: shouldStop);
break;
#endregion

case "Crown of Chaos":
Core.FarmingLogger(req.Name, quant);
Core.EquipClass(ClassType.Farm);
Core.RegisterQuests(9965);
while (!Bot.ShouldExit && !Core.CheckInventory(req.Name, quant))
{
Core.HuntMonster("hiddenduat", "Anubian Overseer", "Duanmutef Glyph", 6, log: false);
Core.HuntMonster("hiddenduat", "Pharaoh Neith", "Neith's Uraeus", log: false);
Core.HuntMonster("hiddenduat", "Umbral Chaos", "Apophis' Violet Favor", log: false);
Bot.Wait.ForPickup(req.Name);
}
Core.CancelRegisteredQuests();
break;

}
}
}

public List<IOption> Select = new()
{
new Option<bool>("88090", "Apophis Medjai", "Mode: [select] only\nShould the bot buy \"Apophis Medjai\" ?", false),
new Option<bool>("88091", "Apophis Medjai Hair", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Hair\" ?", false),
new Option<bool>("88092", "Apophis Medjai Locks", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Locks\" ?", false),
new Option<bool>("88093", "Apophis Medjai Bangs", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Bangs\" ?", false),
new Option<bool>("88094", "Apophis Medjai Morph", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Morph\" ?", false),
new Option<bool>("88095", "Apophis Medjai Visage", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Visage\" ?", false),
new Option<bool>("88096", "Apophis Medjai Bangs Visage", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Bangs Visage\" ?", false),
new Option<bool>("88097", "Apophis Medjai Horned Morph", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Horned Morph\" ?", false),
new Option<bool>("88098", "Apophis Medjai Horned Visage", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Horned Visage\" ?", false),
new Option<bool>("88099", "Apophis Medjai Helm", "Mode: [select] only\nShould the bot buy \"Apophis Medjai Helm\" ?", false),
new Option<bool>("88100", "Dark Medjai Cape", "Mode: [select] only\nShould the bot buy \"Dark Medjai Cape\" ?", false),
new Option<bool>("88103", "Umbral Scythe of Aaru", "Mode: [select] only\nShould the bot buy \"Umbral Scythe of Aaru\" ?", false),
new Option<bool>("88104", "Umbral Bow of Aaru", "Mode: [select] only\nShould the bot buy \"Umbral Bow of Aaru\" ?", false),
};
}
28 changes: 28 additions & 0 deletions Seasonal/BlackFriday/ShadowofDoom/04ShadowDuat.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*
name: Shadow Duat
description: Does the /shadowduat storyline
tags: shadow of doom, shadowduat, shadow, duat, story, saga, zhoom
*/
//cs_include Scripts/CoreBots.cs
//cs_include Scripts/CoreStory.cs
//cs_include Scripts/Seasonal/BlackFriday/ShadowofDoom/CoreShadowofDoom.cs
using Skua.Core.Interfaces;

public class ShadowDuat
{
private IScriptInterface Bot => IScriptInterface.Instance;
private CoreBots Core => CoreBots.Instance;
private CoreStory Story = new();
private CoreShadowofDoom CoreSoD = new();

public void ScriptMain(IScriptInterface Bot)
{
Core.SetOptions();

CoreSoD.ShadowDuat();

Core.SetOptions(false);
}


}
28 changes: 28 additions & 0 deletions Seasonal/BlackFriday/ShadowofDoom/05HiddenDuat.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*
name: Hidden Palace of Duat
description: Does the /hiddenduat storyline
tags: shadow of doom, hiddenduat, hidden, duat, story, saga, zhoom, hidden palace,palace
*/
//cs_include Scripts/CoreBots.cs
//cs_include Scripts/CoreStory.cs
//cs_include Scripts/Seasonal/BlackFriday/ShadowofDoom/CoreShadowofDoom.cs
using Skua.Core.Interfaces;

public class HiddenDuat
{
private IScriptInterface Bot => IScriptInterface.Instance;
private CoreBots Core => CoreBots.Instance;
private CoreStory Story = new();
private CoreShadowofDoom CoreSoD = new();

public void ScriptMain(IScriptInterface Bot)
{
Core.SetOptions();

CoreSoD.HiddenDuat();

Core.SetOptions(false);
}


}
167 changes: 167 additions & 0 deletions Seasonal/BlackFriday/ShadowofDoom/CoreShadowofDoom.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ public void DoAll(bool ReturnEarly = false)
ShadowBattleon();
Camlan(ReturnEarly);
LotusTomb();
ShadowDuat();
HiddenDuat();
}

public void ShadowBattleon()
Expand Down Expand Up @@ -213,6 +215,171 @@ public void LotusTomb()


}

public void ShadowDuat()
{
if (Core.isCompletedBefore(9943))
return;

LotusTomb();

Story.PreLoad(this);

#region Useable Monsters
string[] UseableMonsters = new[]
{
"Umbral Serpent", // UseableMonsters[0],
"Umbral Tomb Hound", // UseableMonsters[1],
"Umbral Sphinx", // UseableMonsters[2],
"Royal Umbral Guard", // UseableMonsters[3],
"Apophis Chantress", // UseableMonsters[4],
"DoomKnight Dryden", // UseableMonsters[5]
};
#endregion Useable Monsters

// 9938 | Shadow Duat Medal
if (!Story.QuestProgression(9938))
{
Core.HuntMonsterQuest(9938,
("shadowduat", UseableMonsters[0], ClassType.Solo));
}

// 9940 | Funerary Shesepankh
if (!Story.QuestProgression(9940))
{
Core.HuntMonsterQuest(9940,
("shadowduat", UseableMonsters[2], ClassType.Solo));
}


// 9941 | Old Guarde
if (!Story.QuestProgression(9941))
{
Core.HuntMonsterQuest(9941,
("shadowduat", UseableMonsters[3], ClassType.Solo));
}


// 9942 | Enemy of the Sun
if (!Story.QuestProgression(9942))
{
Core.HuntMonsterQuest(9942,
("shadowduat", UseableMonsters[4], ClassType.Solo));
}


// 9943 | Doomed Heir
if (!Story.QuestProgression(9943))
{
Core.HuntMonsterQuest(9943,
("shadowduat", UseableMonsters[5], ClassType.Solo));
}

}

public void HiddenDuat()
{
if (Core.isCompletedBefore(9964))
return;

ShadowDuat();

Story.PreLoad(this);

#region Useable Monsters
string[] UseableMonsters = new[]
{
"Umbral Sphinx", // UseableMonsters[0],
"Depths of Isfet", // UseableMonsters[1],
"Umbral Royal Guard", // UseableMonsters[2],
"Royal Mummy", // UseableMonsters[3],
"Anubian Overseer", // UseableMonsters[4],
"Pharaoh Neith", // UseableMonsters[5],
"Umbral Chaos", // UseableMonsters[6]
};
#endregion Useable Monsters

// 9955 | Eclipsed Memory
if (!Story.QuestProgression(9955))
{
Story.KillQuest(9955, "hiddenduat", UseableMonsters[0]);
Story.MapItemQuest(9955, "hiddenduat", 13812);
}


// 9956 | Sons in Spirit
if (!Story.QuestProgression(9956))
{
Core.HuntMonsterQuest(9956,
("hiddenduat", UseableMonsters[2], ClassType.Solo));
}


// 9957 | Cleopatra's Asp
if (!Story.QuestProgression(9957))
{
Story.MapItemQuest(9957, "hiddenduat", new[] { 13813, 13814 });
}


// 9958 | Canopic Guardians
if (!Story.QuestProgression(9958))
{
Core.HuntMonsterQuest(9958,
("hiddenduat", UseableMonsters[0], ClassType.Solo),
("hiddenduat", UseableMonsters[2], ClassType.Solo));
}


// 9959 | Lum'ah
if (!Story.QuestProgression(9959))
{
Story.KillQuest(9959, "hiddenduat", UseableMonsters[3]);
Story.MapItemQuest(9959, "hiddenduat", 13815);
}


// 9960 | Asyut's Hounds
if (!Story.QuestProgression(9960))
{
Core.HuntMonsterQuest(9960,
("hiddenduat", UseableMonsters[4], ClassType.Solo));
}


// 9961 | Chaotic Magnetism
if (!Story.QuestProgression(9961))
{
Story.MapItemQuest(9961, "hiddenduat", new[] { 13816, 13817 });
}


// 9962 | Warrior's Death
if (!Story.QuestProgression(9962))
{
Story.KillQuest(9962, "hiddenduat", new[] { UseableMonsters[3], UseableMonsters[4] });
Story.MapItemQuest(9962, "hiddenduat", 13818);
}


// 9963 | Uraeus
if (!Story.QuestProgression(9963))
{
Core.HuntMonsterQuest(9963,
("hiddenduat", UseableMonsters[5], ClassType.Solo));
}


// 9964 | Dragon of Duat
if (!Story.QuestProgression(9964))
{
Core.HuntMonsterQuest(9964,
("hiddenduat", UseableMonsters[6], ClassType.Solo));
}


}

}


Expand Down

0 comments on commit 1aeb074

Please sign in to comment.