Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
432 changes: 350 additions & 82 deletions Source/relay/Guide/Items of the Month/Red Nosed Snapper.ash

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion Source/relay/Guide/Main.ash
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ void runMain(string relay_filename)
print_html("Form fields: " + form_fields.to_json());


locationCompatibilityInit();
PageInit();
ChecklistInit();
setUpCSSStyles();
Expand Down
2 changes: 1 addition & 1 deletion Source/relay/Guide/Quests/Azazel.ash
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ void QAzazelGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int
entry.subentries.listAppend(subentry);
}

if ((my_path_id() == PATH_TEETOTALER || my_path_id() == PATH_AVATAR_OF_BORIS || my_path_id() == PATH_ZOMBIE_SLAYER) && availableFullness() < 5)
if ((my_path_id() == PATH_TEETOTALER || my_path_id() == PATH_AVATAR_OF_BORIS || my_path_id() == PATH_ZOMBIE_SLAYER || my_path_id() == PATH_OF_THE_PLUMBER) && availableFullness() < 5)
entry.subentries.listAppend(ChecklistSubentryMake(HTMLGenerateSpanFont("Won't work, need five fullness to eat lasagna.", "red"), "", ""));

if (my_path_id() == PATH_OXYGENARIAN && availableSpleen() < 5)
Expand Down
9 changes: 9 additions & 0 deletions Source/relay/Guide/Quests/Level 11 - Hidden City.ash
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,16 @@ void QLevel11HiddenCityInit() {
}
}

int lianas_left;
foreach shrine in $locations[a massive ziggurat,an overgrown shrine (northwest),an overgrown shrine (southwest),an overgrown shrine (northeast),an overgrown shrine (southeast)] {
lianas_left += 3 - shrine.numberOfDenseLianaFoughtInShrine();
}
state.state_int["lianas left"] = lianas_left;

if (get_property_int("hiddenBowlingAlleyProgress") >= 1 && get_property_int("hiddenHospitalProgress") >= 1 && get_property_int("hiddenApartmentProgress") >= 1 && get_property_int("hiddenOfficeProgress") >= 1 && $location[a massive Ziggurat].numberOfDenseLianaFoughtInShrine() >= 3 && state.mafia_internal_step >= 4)
state.state_int["lianas left"] = 0;

if (state.state_int["lianas left"] == 0)
state.state_boolean["need machete for liana"] = false;

if (!__misc_state["can equip just about any weapon"]) {
Expand Down
4 changes: 2 additions & 2 deletions Source/relay/Guide/Quests/Level 12.ash
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ void QLevel12Init()
void QLevel12GenerateTasksSidequests(ChecklistEntry [int] task_entries, ChecklistEntry [int] optional_task_entries, ChecklistEntry [int] future_task_entries)
{
QuestState base_quest_state = __quest_state["Level 12"];
if (!base_quest_state.state_boolean["Orchard Finished"])
if (!base_quest_state.state_boolean["Orchard Finished"] && my_path_id() != PATH_2CRS)
{
string [int] details;
string [int] modifiers;
Expand Down Expand Up @@ -202,7 +202,7 @@ void QLevel12GenerateTasksSidequests(ChecklistEntry [int] task_entries, Checklis
}
optional_task_entries.listAppend(ChecklistEntryMake("Island War Farm", "bigisland.php?place=farm", ChecklistSubentryMake("Island War Farm Quest", modifiers, details), $locations[mcmillicancuddy's farm,mcmillicancuddy's barn,mcmillicancuddy's pond,mcmillicancuddy's back 40,mcmillicancuddy's other back 40,mcmillicancuddy's granary,mcmillicancuddy's bog,mcmillicancuddy's family plot,mcmillicancuddy's shady thicket]));
}
if (!base_quest_state.state_boolean["Nuns Finished"])
if (!base_quest_state.state_boolean["Nuns Finished"] && my_path_id() != PATH_2CRS)
{
string [int] details;
int meat_gotten = get_property_int("currentNunneryMeat");
Expand Down
128 changes: 69 additions & 59 deletions Source/relay/Guide/Quests/Manor.ash
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

void QManorInit()
{
QuestState state;
QuestState state;


state.state_boolean["need ballroom song set"] = false;
Expand Down Expand Up @@ -50,64 +50,64 @@ void QManorInit()



if (locationAvailable($location[the haunted ballroom]) && !(state.state_boolean["need ballroom song set"] || state.state_boolean["ballroom needs delay burned"]))
QuestStateParseMafiaQuestPropertyValue(state, "finished");
else
if (locationAvailable($location[the haunted ballroom]) && !(state.state_boolean["need ballroom song set"] || state.state_boolean["ballroom needs delay burned"]))
QuestStateParseMafiaQuestPropertyValue(state, "finished");
else
{
QuestStateParseMafiaQuestPropertyValue(state, "started");
QuestStateParseMafiaQuestPropertyValue(state, "started");
}
if (my_path_id() == PATH_COMMUNITY_SERVICE) QuestStateParseMafiaQuestPropertyValue(state, "finished");
state.quest_name = "Spookyraven Manor Unlock";
state.image_name = "Spookyraven Manor";
state.quest_name = "Spookyraven Manor Unlock";
state.image_name = "Spookyraven Manor";

/*location zone_to_work_on = $location[none];
if (!locationAvailable($location[the haunted billiards room]))
{
zone_to_work_on = $location[the haunted billiards room];
}
else if (!locationAvailable($location[the haunted library]))
{
zone_to_work_on = $location[the haunted library];
}
else if (!locationAvailable($location[the haunted bedroom]))
{
zone_to_work_on = $location[the haunted bedroom];
}
else if (!locationAvailable($location[the haunted ballroom]))
{
zone_to_work_on = $location[the haunted ballroom];
}
state.state_string["zone to work on"] = zone_to_work_on;*/
__quest_state["Manor Unlock"] = state;
/*location zone_to_work_on = $location[none];
if (!locationAvailable($location[the haunted billiards room]))
{
zone_to_work_on = $location[the haunted billiards room];
}
else if (!locationAvailable($location[the haunted library]))
{
zone_to_work_on = $location[the haunted library];
}
else if (!locationAvailable($location[the haunted bedroom]))
{
zone_to_work_on = $location[the haunted bedroom];
}
else if (!locationAvailable($location[the haunted ballroom]))
{
zone_to_work_on = $location[the haunted ballroom];
}
state.state_string["zone to work on"] = zone_to_work_on;*/
__quest_state["Manor Unlock"] = state;
}


void QManorGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int] optional_task_entries, ChecklistEntry [int] future_task_entries)
{
if (!__quest_state["Manor Unlock"].in_progress && __misc_state["in run"])
return;
if (!__quest_state["Manor Unlock"].in_progress && __misc_state["in run"])
return;
if (my_level() < 5 && my_ascensions() == 0 && !QuestState("questM21Dance").in_progress) return; //not yet possible

boolean should_output_optionally = false;
boolean should_output_futurally = false;
QuestState base_quest_state = __quest_state["Manor Unlock"];
QuestState base_quest_state = __quest_state["Manor Unlock"];

boolean [location] relevant_locations = $locations[the haunted kitchen, the haunted library, the haunted billiards room, the haunted bedroom, the haunted ballroom, the haunted gallery, the haunted bathroom];
//$locations[the haunted kitchen, the haunted library, the haunted billiards room, the haunted bedroom, the haunted ballroom];


if (!__misc_state["in run"] && !(relevant_locations contains __last_adventure_location))
return;
ChecklistSubentry subentry;
//subentry.header = "Unlock Spookyraven Manor";
ChecklistSubentry subentry;
//subentry.header = "Unlock Spookyraven Manor";

//This is currently very incomplete, sorry.
string url = "";
string image_name;
string url = "";
string image_name;

boolean ballroom_probably_open = false;
if ($location[the haunted ballroom].turnsAttemptedInLocation() > 0)
Expand Down Expand Up @@ -354,12 +354,11 @@ void QManorGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int]
should_output_futurally = true;
}*/

float drawers_per_turn = 0.0;
float hot_resistance = numeric_modifier("hot resistance");
float stench_resistance = numeric_modifier("stench resistance");
float hot_resistance = MIN(numeric_modifier("hot resistance"), 9.0);
float stench_resistance = MIN(numeric_modifier("stench resistance"), 9.0);

int more_hot_needed = MAX(0, 9 - hot_resistance.to_int());
int more_stench_needed = MAX(0, 9 - stench_resistance.to_int());
int more_hot_needed = 9 - hot_resistance.to_int();
int more_stench_needed = 9 - stench_resistance.to_int();


string [int] needed_resists;
Expand All @@ -370,29 +369,40 @@ void QManorGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int]

//subentry.entries.listAppend("Run 9 " + HTMLGenerateSpanOfClass("hot", "r_element_hot") + " resistance and " + HTMLGenerateSpanOfClass("stench", "r_element_stench") + " resistance to search faster.");

drawers_per_turn = 0.5 * MIN(4.0, MAX(1.0, 1.0 + hot_resistance / 3.0)) + 0.5 * MIN(4.0, MAX(1.0, 1.0 + stench_resistance / 3.0));
drawers_per_turn = MAX(1.0, drawers_per_turn); //zero-divide safety backup
float drawers_per_turn = 1.0 + MAX(hot_resistance / 6.0, 0.0) + MAX(stench_resistance / 6.0, 0.0);

float drawers_needed = MAX(0, 21 - get_property_int("manorDrawerCount"));

int total_turns = ceil(drawers_needed / drawers_per_turn) + 1;

if (needed_resists.count() > 0 && total_turns > 1)
subentry.entries.listAppend("Run " + needed_resists.listJoinComponents(", ", "and") + " to search faster.");
subentry.entries.listAppend(drawers_per_turn.roundForOutput(1) + " drawers searched per turn.|~" + pluralise(total_turns, "turn", "turns") + " remaining.");

if (__misc_state["have hipster"])
subentry.modifiers.listAppend(__misc_state_string["hipster name"]);
if (total_turns > 1)
{
subentry.modifiers.listAppend(HTMLGenerateSpanOfClass("hot res", "r_element_hot_desaturated"));
subentry.modifiers.listAppend(HTMLGenerateSpanOfClass("stench res", "r_element_stench_desaturated"));
if (drawers_needed == 0.0)
subentry.entries.listAppend("Find the key next turn.");
else {
string line;
if (hot_resistance <= 0 && stench_resistance <= 0)
line = "1 drawer"; //roundForOutput returns a string, incompatible with pluralise()
else
line = drawers_per_turn.roundForOutput(1) + " drawers";
line += " searched per turn.|";

if (drawers_needed > drawers_per_turn.floor()) {
subentry.modifiers.listAppend(HTMLGenerateSpanOfClass("hot res", "r_element_hot_desaturated"));
subentry.modifiers.listAppend(HTMLGenerateSpanOfClass("stench res", "r_element_stench_desaturated"));

line += "~";
if (needed_resists.count() > 0) {
subentry.entries.listAppend("Run " + needed_resists.listJoinComponents(", ", "and") + " to search faster.");
if (!__misc_state["familiars temporarily blocked"] && $familiar[exotic parrot].familiar_is_usable() && my_familiar() != $familiar[exotic parrot])
subentry.entries.listAppend("Possibly bring along your exotic parrot.");
}
}

line += total_turns + " turns remaining.";
subentry.entries.listAppend(line);
}

if (!__misc_state["familiars temporarily blocked"] && $familiar[exotic parrot].familiar_is_usable() && my_familiar() != $familiar[exotic parrot] && (hot_resistance < 9.0 || stench_resistance < 9.0) && total_turns > 1)
{
subentry.entries.listAppend("Possibly bring along your exotic parrot.");
}
if (__misc_state["have hipster"])
subentry.modifiers.listAppend(__misc_state_string["hipster name"]);

if (inebriety_limit() > 10 && my_inebriety() < 10)
subentry.entries.listAppend("Try not to drink past ten, the billiards room is next.");
Expand Down Expand Up @@ -523,7 +533,7 @@ void QManorGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int]
}

}
if (subentry.header != "")
if (subentry.header != "")
{
if (image_name.length() == 0)
image_name = base_quest_state.image_name;
Expand Down
2 changes: 2 additions & 0 deletions Source/relay/Guide/Quests/Pirate.ash
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ void QPirateInit()

void QPirateCoveGenerateTasks(ChecklistEntry [int] task_entries, ChecklistEntry [int] optional_task_entries, ChecklistEntry [int] future_task_entries)
{
if (__quest_state["Island War"].state_boolean["War in progress"]) return;

QuestState base_quest_state = __quest_state["Pirate Quest"];
ChecklistSubentry subentry;
subentry.header = base_quest_state.quest_name;
Expand Down
Loading