diff --git a/optional/interfaces/gametabs/quests.simba b/optional/interfaces/gametabs/quests.simba new file mode 100644 index 00000000..d89ae28b --- /dev/null +++ b/optional/interfaces/gametabs/quests.simba @@ -0,0 +1,313 @@ +{$DEFINE WL_QUESTS_INCLUDED} +{$IFNDEF WL_OSR} + {$I WaspLib/osr.simba} +{$ENDIF} + +//Made by Bootie +type + ERSQuestTab = (CHARACTER_SUMMARY, QUEST_LIST, ACHIEVEMENT_DIARIES); + ERSQuestStatus = (NOT_STARTED, IN_PROGRESS, COMPLETED) + + TRSQuests = record(TRSInterface) + Tabs: array [ERSQuestTab] of TBox; + QuestStatus: TJSONObject; + Cached: Boolean; + QuestNames: TStringArray; + end; + +function TRSQuests.QuestsList(): TStringArray; +var + http: Int32; + page, f2p, p2p, mini, str: String; + temp, f2pQuests, p2pQuests, miniQuests: TStringArray; +begin + http := InitializeHTTPClient(); + SetHTTPUserAgent(http, 'Simba Quest Scraper'); + + // Fetch the page content + page := GetHTTPPage(http, 'https://oldschool.runescape.wiki/w/Quests/List'); + + mini := Between('are groups of objectives that, unlike', '>See also', 'id="Members''_quests">Members'' quests', page); + f2p := Between('