Cursed Warehouse support

Ethelred

Member
Since the cursed warehouse is probably limited time content, are there any plans to add support to mafia for the warehouse? Maybe a warehouse(x,y, z) command? Or even warehouse( item )? Alternatively, does anybody have a script to support either of those? My scripting abilities are too limited to figure out out how to pick the choice adventure and supply the parameters. With 20 items to get, I don't relish repeating all that for each char.

Thanks in advance.
 

ckb

Minion
Staff member
Since the cursed warehouse is probably limited time content, are there any plans to add support to mafia for the warehouse? Maybe a warehouse(x,y, z) command? Or even warehouse( item )? Alternatively, does anybody have a script to support either of those? My scripting abilities are too limited to figure out out how to pick the choice adventure and supply the parameters. With 20 items to get, I don't relish repeating all that for each char.

Thanks in advance.

This ash function will use warehouse keys at location XX,YY,ZZ.
Here is some code to use it to visit the warehouse and loot it at that location.

PHP:
void C17Warehouse(int XX, int YY, int ZZ) {
	visit_url("place.php?whichplace=crimbo17_silentnight&action=c rimbo17_warehouse");
	visit_url("choice.php?whichchoice=1273&option=1&pwd=&num1="+XX+"+&num2="+YY+"&num3="+ZZ, true);
}

void main() {
	C17Warehouse(37, 23, 11);
	C17Warehouse(14, 1, 20);
}
 
Last edited:

lostcalpolydude

Developer
Staff member
You actually need to visit place.php?whichplace=crimbo17_silentnight&action=crimbo17_warehouse once to enter the choice before visiting any number of coordinates.
 

ckb

Minion
Staff member
You actually need to visit place.php?whichplace=crimbo17_silentnight&action=crimbo17_warehouse once to enter the choice before visiting any number of coordinates.

Are you sure? Is it once per login? The code above worked for me.
Edit: I added the place visit anyway.
 
Last edited:

lostcalpolydude

Developer
Staff member
Are you sure? Is it once per login? The code above worked for me.
Edit: I added the place visit anyway.

Visiting that page will keep you in that choice until you adventure somewhere, or enter another choice (florist friar, for example, which is a place you can easily visit to see that the choice.php URLs then stop working).

I have to deal with it all the time when adding new content to mafia, so yes, I'm sure.
 

ckb

Minion
Staff member
Visiting that page will keep you in that choice until you adventure somewhere, or enter another choice (florist friar, for example, which is a place you can easily visit to see that the choice.php URLs then stop working).

I have to deal with it all the time when adding new content to mafia, so yes, I'm sure.

I'll believe that rather than my fuzzy memory. I know the original code worked, but I was also likely already in the choice from testing the script vs. browser trials.
 

Veracity

Developer
Staff member
Here's a script you might find useful. It takes five parameters. If you don't specify them when you invoke it, it prompts for each in turn (since that's how ASH works).

boolean equipment - "true" if it should try to get the equipment, "false" otherwise.

The assumption is that you never need more than one of each, so, if a piece is "available" to you - using your standard item acquisition settings it won't try to get another one. I'd suggest you just keep these items in inventory before running the script.

int wines - number of mime army wines to get
int rations - number of mime army rations to get
int superserums - number of mime army superserums to get
int camouflage - number of mime army camouflage kits to get

Since you can only loot a particular place in the warehouse once per character, there are built-in lists of "confirmed" (per the community spading spreadsheet) locations that contain each of these items. The script doesn't remember which locations you have looted; if you run it multiple times, it will try to loot squares you've already visited. It will detect the failure and move on, so, until it runs out of "confirmed" squares to loot, it'll Just Work.

Feel free to augment the lists with non-"confirmed" squares if you want.
 

Attachments

  • warehouse.ash
    5.9 KB · Views: 67
Last edited:

Ethelred

Member
Here's a script you might find useful. It takes five parameters. If you don't specify them when you invoke it, it prompts for each in turn (since that's how ASH works).

.... [Instructions edited out]


Since you can only loot a particular place in the warehouse once per character, there are built-in lists of "confirmed" (per the community spading spreadsheet) locations that contain each of these items. The script doesn't remember which locations you have looted; if you run it multiple times, it will try to loot squares you've already visited. It will detect the failure and move on, so, until it runs out of "confirmed" squares to loot, it'll Just Work.

Feel free to augment the lists with non-"confirmed" squares if you want.

Awesome! Thank you very much. Way more than I was expecting. What a lovely Crimbo present!
 
Hmm, it's not working completely right, it couldn't find any miming gear or morale insignias for me. Still, it was easier to get those by hand afterwards than having to get everything by hand, especially a stack of consumables from differing coordinates.
 

Crowther

Active member
That was so much better than the one I wrote. Sadly (or happily) warehouse keys are in such an abundance I ran out of spaded places to find consumables.
 

Veracity

Developer
Staff member
Thanks!

Here's a version which I think is a little better; rather than having a record with three fields for the location, it simply uses an array with three elements. All that work I made to soup up Array Literals paid off...
 

Attachments

  • warehouse.ash
    5.2 KB · Views: 46
Nice, thanks for this script.
I wanted more data, so for people that (like me) want to stock up like crazy, and don't mind a little risk:
Here's a version which includes up to 5 confirmed locations for each non-consumable, and every location listed in the spreadsheet for the consumables, which means there's probably a bunch of them wrong, but it's still way faster than trying to find all of them by hand.
 

Attachments

  • warehouse.ash
    16.8 KB · Views: 41
Just wanted to say thank you to veracity and dictator.
(for those wondering about how risky it is- dictator's version had one location wrong in 80 attempts on consumables. I am now the proud owner of two pairs of mining corduroys- a small price to pay for the convenience and time saved.)
 
Roderick the Unmarried reported 6 corrections to me after collecting 100 consumables (no testing for the equipment), so here's a slightly updated script.
 

Attachments

  • warehouse.ash
    16.7 KB · Views: 52

Crowther

Active member
The URL to prime the warehouse changed. This worked for me:

Code:
        visit_url( "inv_use.php?pwd&which=3&whichitem=9627");
 

Veracity

Developer
Staff member
Oh, sweet. You can just use a warehouse key, rather than clicking on a location which will fade into the mists, by and by.
Presumably this means that the content will be available as long as warehouse keys exist.

I'd expect this to work in this script to "prime" it, once we mark the warehouse key as "usable" (or "reusable").

Code:
use( 1, KEY );
I'll try it when I get home tonight.
 
It seems that we can't generate new keys though- they are gone from the cheer store, and CDM said they aren't/shouldn't be pickpocketable anymore.
 

Veracity

Developer
Staff member
I see neither Tammy's Camp nor the Cheerless Spire on the map any more.
Nor do I see either an Announcement or a Trivial Update mentioning this.
That was abrupt!
 
Yay, updates.

(Use didn't actually work, because it leads you to a choice adventure and use tries to automate that and fails since it's an unknown choice adventure, but using visit_url() to call the use link worked).
 

Attachments

  • warehouse.ash
    16.9 KB · Views: 31
Top