ereinion
Member
I'm trying to write a script to see what hobo codes I have left to find:
I think it works ok-ish, though I'm not certain if all the strings match what's going to appear at the page. However I am having trouble matching one which does appear there (i.e. one I've already found), namely "The "Fun" House". As you can see I have tried escaping the quotation marks, which didn't help. Having no idea of what method I should use to get the strings to match, I am turning to you for help.
So help, please?
PHP:
void main() {
string log = visit_url("questlog.php?which=5");
boolean allFound = true;
string[string] areas;
areas["The Penultimate Fantasy Airship"] = "There're no prerequisits to access the area.";
areas["The \"Fun House\""] = "There're no prerequisits to access the area.";
areas["The Enormous Greater-Than Sign"] = "It's only available before unlocking the Dungeons of Doom.";
areas["The Battlefield (Frat Warrior Fatigues)"] = "It's only available during the level 12 quest.";
areas["The Arid, Extra-Dry Desert"] = "There're no prerequisits to access the area.";
areas["The Sleazy Back Alley"] = "There're no prerequisits to access the area.";
areas["Thugnderdome"] = "It's only available under moxie signs (Wombat, Blender or Packrat).";
areas["Belowdecks"] = "There're no prerequisits to access the area (but it's unavailable during the Hippy War).";
areas["Camp Logging Camp"] = "It's only available under mysticality signs (Platypus, Opossum or Marmot).";
areas["Bugbear Pens"] = "They are only available under muscle signs (Mongoose, Wallaby or Vole). It's also unavailable after beating Felonia";
areas["The Defiled Nook"] = "The area is only available during the level 7 quest.";
areas["The Poker Room"] = "There're no prerequisits to access the area.";
areas["White Citadel"] = "It's only available before unlocking the citadel.";
areas["Noob Cave"] = "There're no prerequisits to access the area.";
areas["Cobb's Knob Menagerie, Level 3"] = "There're no prerequisits to access the area.";
areas["The Limerick Dungeon"] = "There're no prerequisits to access the area.";
areas["Lair of the Ninja Snowmen"] = "There're no prerequisits to access the area.";
areas["Pre-Cyrpt Cemetary"] = "The area is only available before the Cyrpt.";
areas["Cola Wars Battlefield (Undisguised)"] = "It is available between levels four and six.";
areas["The eXtreme Slope"] = "There're no prerequisits to access the area.";
foreach loc in areas {
if (!log.contains_text(loc)) {
allFound = false;
print("You need to find the code in " + loc + ". " + areas[loc], "green");
}
}
if (allFound) {
print("You've already found all the hobo-codes", "green");
}
}
So help, please?
Last edited: