New Content - Implemented Fight another link for tavern faucet

Yendor

Member
April 30, 2012 - Fighting a rat out of the faucet now gives you a one-click link to fight another one.

The link is: cellar.php?action=autofaucet
 

Yendor

Member
Currently, adventuring in the cellar post-quest goes to the choice adventure, then the combat. The autofaucet link skips the choice and goes straight to the combat. Mafia also doesn't recognize the link as starting a new adventure.
 

Orbrisa

Member
I don't know if the OP was asking for this, but a native way to automate repeatedly fighting at the faucet would be useful. (If there already is one, and I just haven't found it, please pardon my idiocy.)
 

Veracity

Developer
Staff member
I don't know if the OP was asking for this, but a native way to automate repeatedly fighting at the faucet would be useful.
I simply selected "Tavern Cellar" in the list of adventure locations, told it to go there 35 times, and it did so. It used the old method of going to that square and selecting the choice, rather than the new single-server-hit method, but it worked.

As Yendor points out, we could streamline that.
 

lostcalpolydude

Developer
Staff member
Adding it to the list of zones was straightforward. Getting the encounter recognized (added to the list of encounters this session) wasn't too bad. When I saw that automating went to cellar.php?action.php&action=autofaucet (which somehow ends up at the choice adventure to fight a rat...), I realized I don't really know how the cellar code works.
 

Veracity

Developer
Staff member
I experimented:

Requesting: http://www.kingdomofloathing.com/cellar.php?action=autofaucet
Retrieved: http://www.kingdomofloathing.com/cellar.php?action=autofaucet
Redirect to: choice.php?forceoption=1
Requesting: http://www.kingdomofloathing.com/choice.php?forceoption=1
Retrieved: http://www.kingdomofloathing.com/choice.php?forceoption=1
Redirect to: fight.php?ireallymeanit=1336056261
Requesting: http://www.kingdomofloathing.com/fight.php?ireallymeanit=1336056261
Retrieved: http://www.kingdomofloathing.com/fight.php?ireallymeanit=1336056261

... and we are finally in the fight.

In other words, there seems to be little benefit for KoLmafia to use "cellar.php?action=autofaucet"; it still redirects to choice.php and auto-selects option 1. I suppose that is one fewer server hit; we don't have to retrieve choice.php and then submit it again with the correct option chosen.

We should recognize this and log it correctly. And the "choice.php?forceoption=1" is new and should be recognized and logged correctly, I guess, although our usual mechanism of parsing the choice page to figure out which choice we were shunted to won't work.

This does not seem like a high priority. You want to fight lots of rats? Just do as I suggested for autoadventuring (which, unfortunately, will probably explore the rest of the cellar before going to the rat faucet; we could add a Tavern Cellar (Rat Faucet) adventure to force it) and you will squeeze out rats almost as efficiently, server-hit-wise, as using the link in the Relay Browser.
 

Veracity

Developer
Staff member
Code:
r15915 | veracity0 | 2015-06-06 15:41:39 -0400 (Sat, 06 Jun 2015) | 3 lines

Make cellar.php?action=autofaucet log correctly. Use that action when automating
the Tavern Cellar, to eliminate unnecessary server hits & redirections.
Sometimes it takes years before a dev is interested in implementing something...
 
Top