bumcheekcend.ash - A zero setup semi-automated ascension script!

Oh, right. I haven't played in a while!

I bought 5 chewing gums on a string and tried to find the sewers just now. Heh.

Thanks for your quick response and hardwork (Y)! I'm looking forward to the fix.

EDIT: another newbie question..

why is it that when I try to use 5 hair spray, kolmafia gives me this response? Same with soda water and fortune cookies, it's almost as if it does not realise that I have access to the market... I'm using r8803

> use 5 hair spray

You need 5 more hair spray to continue.
 
Last edited:
Ballroom is still an issue it seems.
Code:
I need 85 base moxie
BCC: Attempting to get clovers to level with.
BCC: Getting Clovers
Searching for "chewing gum on a string"...
Purchasing chewing gum on a string (1 @ 50)...
You acquire an item: chewing gum on a string
You spent 50 Meat
Purchases complete.
Using 1 chewing gum on a string...
You acquire an item: worthless gewgaw
Finished using 1 chewing gum on a string.
Robbing the hermit...
Searching for "hermit permit"...
Purchasing hermit permit (1 @ 100)...
You acquire an item: hermit permit
You spent 100 Meat
Purchases complete.
Robbing the hermit...
Robbing the hermit...
You acquire an item: ten-leaf clover
Hermit successfully looted!
Using 1 ten-leaf clover...
You acquire an item: disassembled clover
Finished using 1 ten-leaf clover.
bcasc_lastHermitCloverGet => 20101205
Conditions list cleared.
Checking for familiar 'slimeling' where x=1
Checking for familiar 'baby gravy fairy' where x=2
Putting Gon the Jumpsuited Hound Dog back into terrarium...
Taking Champi(nj)on the Baby Gravy Fairy out of terrarium...
Condition set: dance card
dance card
Resetting mind control device...
Mind control device reset.

Request 1 of 5 (Manor2: Haunted Ballroom) in progress...
You can't get to that area.

Condition already exists: dance card
dance card
Resetting mind control device...
Mind control device reset.

Request 1 of 5 (Manor2: Haunted Ballroom) in progress...
You can't get to that area.

Condition already exists: dance card
dance card
Resetting mind control device...
Mind control device reset.

Request 1 of 5 (Manor2: Haunted Ballroom) in progress...
You can't get to that area.

Condition already exists: dance card
dance card
Resetting mind control device...
Mind control device reset.

Request 1 of 5 (Manor2: Haunted Ballroom) in progress...
You can't get to that area.

Condition already exists: dance card
dance card
Resetting mind control device...
Mind control device reset.

Request 1 of 5 (Manor2: Haunted Ballroom) in progress...
You can't get to that area.
I have the settings to open the Ballroom to True like this:
Code:
//Set this to true if you want the script to do the Bedroom for you after the Bonerdagon, automatically 
opening up the ballroom. 
//If you have few skills, you may want to do this manually. 
bcasc_bedroom = true;

EDIT1:
Also, I am now halfway through lvl9 and no chef or bartender in a box yet. It seems the script did not even get the Fernswarthy's key from the cemetary, so no access to the Ruins and the brains. No beer lenses either, and yes it is set to True in the settings.

EDIT2:
I also wonder if it is optimal to skip getting the advanced cocktailcrafting kit and oven? Without them I cant even make reagent potions..
Btw, are those something that Mafia should get on its own as in "buying thinsg from an NPC to create the items"?

EDIT3: Just now after lvl9 i seem that the script have started to actually cast the buffs in the mood, such as the +noncombats etc. I'm no AT now so it is not due to access to MMJ.
 
Last edited:
The script gets tenders using clovers after the bonerdagon, by clovering the cemetary.

The script doesn't buy the advanced cocktail kit and oven, I should add that in.

The script will apply buffs if you're over level 9, have the KGE outfit or have over 5K meat or have over 100MP
 
The script gets tenders using clovers after the bonerdagon, by clovering the cemetary.
Then I have a problem.
Code:
Level 7 Starting
BCC: We have completed the stage [manor2ndfloor].
BCC: We have completed the stage [cyrpt].
BCC: We have completed the stage [innaboxen].
I have manually done the innaboxes and opened the 2nd floor using another script, but the Bonerdagon is still alive and is shown as completed in the list.
Or is the Bonerdagon a separate flag? If so, I am about to start the lvl11 quest and Bonerdagon is still alive.
Safe Adventuring on the Wiki show the Haert to need 101 moxie though, and considering I have 180 buffed moxie atm, then even with ML+10 I should have no trouble taking down the bonerdagon, but the script dont seem to want to do it.
 
In 0.11, levelMe still appears to be broken when the goal is to hit a buffed level of moxie. "goal set +XXX moxie" just sets the goal for "0/0/0 substats" and adventures forever. Here's the fix:

Code:
boolean levelMe(int sMox, boolean needBaseStat) {
	[b]if (needBaseStat) {
		//print("Need to Level up a bit to get at least "+sMox+" base Moxie", "fuchsia");
		if (my_basestat($stat[Moxie]) >= sMox) {
			//print("It turns out I have enough base moxie anyway.");
			return true;
		}
	} else {
		cli_execute("maximize moxie");
		setMood("");
		cli_execute("mood execute");

		int extraMoxieNeeded = sMox - my_buffedstat($stat[Moxie]);
		//print("Need to Level up a bit to get at least "+sMox+" buffed Moxie. This means getting "+extraMoxieNeeded+" Moxie.", "fuchsia");
		sMox = my_basestat($stat[Moxie]) + extraMoxieNeeded;
		if (extraMoxieNeeded <= 0) {
			print("I had enough buffed moxie anyway.", "fuchsia");
			return true;
		}
	}
	cli_execute("goal clear; goal set "+sMox+" Moxie");[/b]

	if (have_effect($effect[Beaten Up]) > 0) {
		cli_execute("uneffect beaten up");
	}
 
Then I have a problem.
Code:
Level 7 Starting
BCC: We have completed the stage [manor2ndfloor].
BCC: We have completed the stage [cyrpt].
BCC: We have completed the stage [innaboxen].
I have manually done the innaboxes and opened the 2nd floor using another script, but the Bonerdagon is still alive and is shown as completed in the list.
Or is the Bonerdagon a separate flag? If so, I am about to start the lvl11 quest and Bonerdagon is still alive.
Safe Adventuring on the Wiki show the Haert to need 101 moxie though, and considering I have 180 buffed moxie atm, then even with ML+10 I should have no trouble taking down the bonerdagon, but the script dont seem to want to do it.

You can manually set the settings/prefernces to false by using:
Code:
set bcasc_stage_cyrpt = 0 (or any number lower than your current ascensions)
 
You can manually set the settings/prefernces to false by using:
Code:
set bcasc_stage_cyrpt = 0 (or any number lower than your current ascensions)

Yeh just though that it might be the same issue as with the Goblin King, where the Complete flag is set before the boss is actually killed.
 
Here's an automatic mining function. I tested it a fair amount and just used it successfully on my current run. It's smart about Unaccompanied Miner and can also be called to burn teleportitis turns. (I have a patch for teleportitis too, but I'll post that separately.)

Code:
boolean bcascMining() {
	if (checkStage("mining")) return true;

	string trapper = visit_url("trapper.php");
	if (my_level() >= 8 && !contains_text(trapper, "I reckon 3 chunks")) {
		print("Looks like we're done mining.", "purple");
		checkStage("mining", true);
		return true;
	}

	string goalString = get_property("trapperOre");
	item goal = to_item(goalString);

	if (goal != $item[asbestos ore] && goal != $item[chrome ore] && goal != $item[linoleum ore])
		abort("Can't figure out which ore to look for.");

	// Seed ore locations with what mafia knows about.
	int[int] oreLocations;
	string mineLayout = get_property("mineLayout1");
	int start = 0;
	while (true) {
		int num_start = index_of(mineLayout, '#', start);
		if (num_start == -1) break;
		int num_end = index_of(mineLayout, '<', num_start);
		if (num_end == -1) break;
		int end = index_of(mineLayout, '>', num_end);
		if (end == -1) break;

		if (contains_text(substring(mineLayout, num_end, end), goalString)) {
			int spot = to_int(substring(mineLayout, num_start + 1, num_end));
			oreLocations[count(oreLocations)] = spot;
		}
		start = end;
	}

	boolean rowContainsEmpty(string mine, int y)
	{
		for x from 1 to 6 {
			if (contains_text(mine, "Open Cavern (" + x + "," + y + ")"))
				return true;
		}

		return false;
	}

	boolean canMine(string mine, int x, int y, boolean onlySparkly)
	{
		if (x < 0 || x > 7 || y < 0 || y > 7)
			return false;
		int index = x + y * 8; 
		boolean clickable = (index_of(mine, "mining.php?mine=1&which=" + index + "&") != -1);

		if (!clickable || !onlySparkly)
			return clickable;

		return contains_text(mine, "Promising Chunk of Wall (" + x + "," + y + ")");
	}

	int adjacentSparkly(string mine, int index)
	{
		int x = index % 8;
		int y = index / 8;

		if (canMine(mine, x, y - 1, true))
			return index - 8;
		if (canMine(mine, x - 1, y, true))
			return index - 1;
		if (canMine(mine, x + 1, y, true))
			return index + 1;
		if (canMine(mine, x, y + 1, true))
			return index + 8;
		return - 1;
	}

	int findSpot(string mine, boolean[int] rows, boolean[int] cols) {
		foreach sparkly in $booleans[true, false] {
			foreach y in cols {
				foreach x in rows {
					if (canMine(mine, x, y, sparkly))
						return x + y * 8;
				}
			}
		}
		return -1;
	}

	cli_execute("outfit mining");

	while (item_amount(goal) < 3) {
		if (my_hp() == 0) cli_execute("restore hp");
		string mine = visit_url("mining.php?intro=1&mine=1");

		if (contains_text(mine, "You can't mine without the proper equipment."))
			abort("Couldn't equip mining gear.");

		boolean willCostAdventure = contains_text(mine, "takes one Adventure.");
		if (have_skill($skill[Unaccompanied Miner]) && willCostAdventure && have_effect($effect[Teleportitis]) == 0 && my_level() < 12) {
			print("BCC: No more mining today.  I'll come back later.", "purple");
			return false;
		}
		if (my_adventures() == 0 && willCostAdventure) abort("No Adventures");

		int choice = -1;
		string why = "Mining around found ore";
		// Ore is always coincident, so look nearby if we've aleady found some.
		if (count(oreLocations) > 0) {
			foreach key in oreLocations {
				choice = adjacentSparkly(mine, oreLocations[key]);
				if (choice != -1)
					break;
			}
		}

		// Prefer mining the middle first.  It leaves more options.
		boolean[int] rows = $ints[3, 4, 2, 5, 1, 6];

		// First, try to mine up to the top four rows if we haven't yet.
		if (choice == -1 && !rowContainsEmpty(mine, 6)) {
			choice = findSpot(mine, rows, $ints[6]);
			why = "Mining upwards";
		} 

		if (choice == -1 && !rowContainsEmpty(mine, 5)) {
			choice = findSpot(mine, rows, $ints[5]);
			why = "Mining upwards";
		}
				
		// Top three rows contain most ore.  Fourth row may contain ore.
		// Prefer second row and digging towards the middle because it
		// opens up the most potential options.  This could be more
		// optimal, but it's not a bad heuristic.
		if (choice == -1) {
			choice = findSpot(mine, rows, $ints[2, 3, 1, 4]);
			why = "Mining top four rows";
		}

		// There's only four pieces of the same ore in each mine.
		// Maybe you accidentally auto-sold them or something?
		if (choice == -1 || count(oreLocations) == 4) {
			print("BCC: Resetting mine!", "purple");
			visit_url("mining.php?mine=1&reset=1&pwd");
			oreLocations.clear();
			continue;
		}

		print(why + ": " + (choice % 8) + ", " + (choice / 8) + ".", "purple");
		string result = visit_url("mining.php?mine=1&which=" + choice + "&pwd");
		if (index_of(result, goalString) != -1) {
			oreLocations[count(oreLocations)] = choice;
		}
	}

	if (have_effect($effect[Beaten Up]) > 0) cli_execute("unaffect beaten up");
	visit_url("trapper.php");

	checkStage("mining", true);
	return true;
}

Here's the changes to call it along with opening the goatlet. I check the return value from mining because it's smart about using Unaccompanied Miner and so may not have actually finished getting all the ore when it returns.

Code:
boolean bcascTrapper() {
	if (checkStage("trapper")) return true;

	visit_url("trapper.php");
	
	while (index_of(visit_url("trapper.php"), "reckon 3 chunks of") > 0) {
		if (i_a("miner's helmet") == 0 || i_a("7-Foot Dwarven mattock") == 0 || i_a("miner's pants") == 0) {
			bumAdv($location[Itznotyerzitz Mine], "", "hebo", "1 miner's helmet, 1 7-Foot Dwarven mattock, 1 miner's pants", "Getting the Mining Outfit", "", "consultHeBo");
			visit_url("trapper.php");
		}
		[b]if (!bcascMining())
			return false;[/b]
	}
	while (contains_text(visit_url("trapper.php"), "6 chunks of goat cheese")) {
		[b]// It's possible somebody could have opened this manually, but there's
		// no way to determine that before adventuring.
		if (!checkStage("opengoatlet")) {
			cli_execute("outfit mining");
			cli_execute("set choiceAdventure162 = 1");
			adventure(1, $location[Goatlet]);
			checkStage("opengoatlet", true);
		}[/b]

		cli_execute("friars food");
 
Code:
[773] Daily Dungeon (Room 1)
Encounter: Brrrrrr.

Request 2 of 242 (Dungeon: Daily Dungeon) in progress...

[774] Daily Dungeon (Room 2)
Encounter: sabre-toothed lime
Strategy: attack with weapon
Round 0: ferdawoon wins initiative!
Round 1: ferdawoon executes a macro!
Round 1: ferdawoon attacks!
You gain 22 Meat
You gain 3 Muscleboundness
You gain 4 Enchantedness
You gain 5 Cheek

Request 3 of 242 (Dungeon: Daily Dungeon) in progress...
Dance Card counter expired.

Change it so if I have a Dance Card counting down, that it will spend the 4th adv in the Ballroom and then continue with what it was doing, rather than aborting?
 
It would be too complicated to have it check for counters every time an adventure is spend. Do you use a counterScript?
 
If you do have a counterScript, just make sure that it's doing !adventure instead of just adventure. If it's properly !adventuring, it should fail to abort when conditions aren't met after its one adventure.
 
It would be too complicated to have it check for counters every time an adventure is spend. Do you use a counterScript?
Well, Mafia do keep track of it so I guess it would not be that hard, but I can see that it would be a lot of extra work from the script to after every adventure check every counter.

No, not using any such script. On the other hand, Don't Mafia already show this counter in the char pane? It show me the Semirare Window counter, it show me the dance card counter, etc.
 
The point is that mafia's functionality for this is through using a counterScript, not by doing
PHP:
while (my_adventures() > 0) {
adventure(1, <current location);
if (counter("dance card", 0, 0) (!adventure(1, $location[haunted ballroom]));
if (condition met) break;
}

With a counter script active, you can just do
PHP:
adventure(my_adventures(), <current location>, conditions);
and it'll check your counters on each turn, before you adventure...
 
why is it that when I try to use 5 hair spray, kolmafia gives me this response? Same with soda water and fortune cookies, it's almost as if it does not realise that I have access to the market... I'm using r8803

> use 5 hair spray

You need 5 more hair spray to continue.
This can happen if you do not have enough meat.
 
@tianshi - The hair spray thing is not having enough meat. I'm not particularly fussed about fixing that. Autosell some stuff and play manually for a while, get more meat, then crack on with the script.

@Ferdawoon - I'll keep an eye on the innaboxen thing, but haven't had it come up myself. The counters thing is beyond the scope of a script. I don't use, but have heard great things about, Bale's counterchecker script. Have a look.

@picklish - As always, thanks for your additions. I'm actually removing the unaccompanied miner part from your entry - as I'd like to do this all at once, and I tend to find the 5K meat makes things easier for later, but that's brilliant. I really hoped someone would write that part for me :D
 
I don't find that I need the 5k meat at that point (usually because the 23k meat happens immediately afterwards) and there's no hurry to get the 6k meat for the wand before level 9. Rather than removing it, would you mind putting it behind an option instead?
 
I just had it die while trying to unlock the Palindome since it didn't have 60 mysticality. The maximize statement failed (I couldn't equipped the Fledges) and then it went into an infinite loop.
 
I dont see how Diamond studded cane is in any way an optimal weapon for Disco Bandit doing the Battlefield =(
It start well with equipping the didgeridooka, but afer the mood it go for the cane and boybottoms and other notverygood items.
After doing the Orchard manually with no problems, and starting the script again afterwards, it let me use a ranged weapon again.

Code:
Level 12 Starting
BCC:     Starting SideQuest 'arena'
BCC: Starting     SideQuest 'junkyard'
BCC: Starting     SideQuest 'beach'
Maximizing...
210 combinations checked,     best score 219.0
Putting on beer helmet...
Equipment changed.
Wielding     didgeridooka...
Equipment changed.
Putting on distressed denim     pants...
Equipment changed.
Putting on bejeweled pledge pin...
Equipment     changed.
BCC: Starting SideQuest 'orchard'
BCC:     doSideQuest(Orchard)
Resetting mind control device...
Mind     control device reset.
Checking for familiar     'jumpsuited hound dog' where x=1
Conditions list cleared.
Condition     set: filthworm hatchling scent gland
filthworm hatchling scent gland
BCC:     Getting the Hatchling Gland (1/3)

When I run low on     Butt-Rock Hair, use 5 hair spray
When I run low on Butt-Rock Hair, use     5 hair spray
When I run low on The Moxious Madrigal, cast 1 The Moxious     Madrigal
When I run low on Butt-Rock Hair, use 5 hair spray
When I     run low on Mariachi Mood, cast 1 Moxie of the Mariachi
When I run low     on The Moxious Madrigal, cast 1 The Moxious Madrigal
When I run low on     Butt-Rock Hair, use 5 hair spray
When I run low on Disco State of Mind,     cast 1 Disco Aerobics
When I run low on Mariachi Mood, cast 1 Moxie of     the Mariachi
When I run low on The Moxious Madrigal, cast 1 The Moxious     Madrigal
BCC: Need items!
When I run low     on Butt-Rock Hair, use 5 hair spray
When I run low on Disco State of     Mind, cast 1 Disco Aerobics
When I run low on Fat Leon's Phat Loot     Lyric, cast 1 Fat Leon's Phat Loot Lyric
When I run low on Mariachi     Mood, cast 1 Moxie of the Mariachi
When I run low on The Moxious     Madrigal, cast 1 The Moxious Madrigal
When I run low on Butt-Rock Hair,     use 5 hair spray
When I run low on Disco State of Mind, cast 1 Disco     Aerobics
When I run low on Fat Leon's Phat Loot Lyric, cast 1 Fat     Leon's Phat Loot Lyric
When I run low on Leash of Linguini, cast 1     Leash of Linguini
When I run low on Mariachi Mood, cast 1 Moxie of the     Mariachi
When I run low on The Moxious Madrigal, cast 1 The Moxious     Madrigal
Casting The Moxious Madrigal 1 times...
You acquire an     effect: The Moxious Madrigal (duration: 10 Adventures)
The Moxious     Madrigal was successfully cast.
Mood swing complete.
Maximizing...
355     combinations checked, best score 258.93
Putting on worn tophat...
Equipment     changed.
Wielding diamond-studded cane...
Equipment changed.
Holding     wicker shield...
Equipment changed.
Putting on buoybottoms...
Equipment changed.
Putting on     Sneaky Pete's breath spray...
Equipment changed.
Mood swing complete.
BCC:     We should set the MCD if we can.
BCC: We     CAN set the MCD.
Resetting mind control device...
Mind     control device reset.

Request 1 of 64 (Orchard: Hatching Chamber)     in progress...

[1196] Hatching Chamber
Encounter: larval     filthworm
Strategy: attack with weapon
Round 0: ferdawoon wins     initiative!
Round 1: ferdawoon executes a macro!
Round 1: ferdawoon     tries to steal an item!
Round 2: ferdawoon attacks!
Round 3:     ferdawoon attacks!
Round 4: ferdawoon attacks!
Round 5: ferdawoon     attacks!
Round 6: ferdawoon attacks!
Round 7: ferdawoon attacks!
Round     8: ferdawoon attacks!
Round 9: ferdawoon attacks!
Round 10:     ferdawoon attacks!
Round 11: ferdawoon attacks!
Round 12: ferdawoon     attacks!
Round 13: ferdawoon attacks!
Round 14: ferdawoon attacks!
Round     15: ferdawoon attacks!
Round 16: ferdawoon attacks!
Round 17:     ferdawoon attacks!
Round 18: ferdawoon attacks!
You lose 7 hit points
Round     19: ferdawoon attacks!
Round 20: ferdawoon attacks!
Round 21:     ferdawoon attacks!
Round 22: ferdawoon attacks!
Round 23: ferdawoon     attacks!
Round 24: ferdawoon attacks!
Round 25: ferdawoon attacks!
Round     26: ferdawoon attacks!
Round 27: ferdawoon attacks!
Round 28:     ferdawoon attacks!
Round 29: ferdawoon attacks!
Round 30: ferdawoon     attacks!
You lose 3 hit points
Round 31: ferdawoon attacks!

Request     2 of 64 (Orchard: Hatching Chamber) in progress...

[1197] Hatching     Chamber
Encounter: larval filthworm
Strategy: attack with weapon
Round     0: ferdawoon loses initiative!
Round 1: ferdawoon executes a macro!
Round     1: ferdawoon tries to steal an item!
KoLmafia thinks it is round 2 but     KoL thinks it is round 1
Round 2: ferdawoon attacks!
Round 3:     ferdawoon attacks!
Round 4: ferdawoon attacks!
Round 5: ferdawoon     attacks!
Round 6: ferdawoon attacks!
Round 7: ferdawoon attacks!
Round     8: ferdawoon attacks!
Round 9: ferdawoon attacks!
Round 10:     ferdawoon attacks!
Round 11: ferdawoon attacks!
Round 12: ferdawoon     attacks!
Round 13: ferdawoon attacks!
Round 14: ferdawoon attacks!
Round     15: ferdawoon attacks!
Round 16: ferdawoon attacks!
Round 17:     ferdawoon attacks!
Round 18: ferdawoon attacks!
Round 19: ferdawoon     attacks!
Round 20: ferdawoon attacks!
Round 21: ferdawoon attacks!
Round     22: ferdawoon attacks!
Round 23: ferdawoon attacks!
Round 24:     ferdawoon attacks!
Round 25: ferdawoon attacks!
Round 26: ferdawoon     attacks!
Round 27: ferdawoon attacks!
Round 28: ferdawoon attacks!
Round     29: ferdawoon attacks!
Round 30: ferdawoon attacks!
Round 31:     ferdawoon attacks!
Round 32: ferdawoon attacks!

EDIT2:
The lvl12 quest settings seem a bit funky.
I have
Code:
switch (my_name()) {
	case "Ferdawoon":
		bcasc_100familiar = "";
		bcasc_doWarAs = "frat";
		bcasc_doSideQuestArena = true;
		bcasc_doSideQuestJunkyard = true;
		bcasc_doSideQuestBeach = true;
		bcasc_doSideQuestOrchard = true;
		bcasc_doSideQuestNuns = true;
		bcasc_doSideQuestDooks = true;
	break;
but it seems I had:
Code:
		//Indicate whether or not you want to do each of the sidequests.
		bcasc_doSideQuestArena = true;
		bcasc_doSideQuestJunkyard = true;
		bcasc_doSideQuestBeach = true;
		bcasc_doSideQuestOrchard = true;
		bcasc_doSideQuestNuns = false;
		bcasc_doSideQuestDooks = false;
	break;
Now, if the first setting say it should do all the sidequests, but the script go after what the 2nd setting says, why have the first there at all? Atm I am 768 Hippies through the Battlefield and no Nuns or Farm =S
Setting the 2nd setting to all True and restarting the script, It started the Nuns.
 
Last edited:
Back
Top