Feature Do not assume overdrinking is authorized when a player drinks with 0 adventures left

slyz

Developer
I ran this CLI script from the gCLI:
Code:
equip tuxedo shirt
drink 4 rockin' wagon ;
drink 1 black tan
drink 1 shot of blackberry schnapps
I forgot that I had gotten booze from the Hobopolis Marketplace (Mafia was correctly showing my inebriety of 5/19).

Running the CLI script resulted in:
Code:
> call temp2

Putting on tuxedo shirt...
Equipment changed.
Since you are not in a Moxie sign, you may not visit the brewery.
Verifying ingredients for rockin' wagon (4)...
[...]
Successfully created rockin' wagon (4)
Drinking 4 rockin' wagon...
You gain 21 Adventures
You gain 35 Smarm
You gain 4 Drunkenness
You gain 16 Adventures
You gain 36 Sarcasm
You gain 4 Drunkenness
You gain 18 Adventures
You gain 34 Chutzpah
You gain 4 Drunkenness
You gain 21 Adventures
You gain 34 Smarm
You gain 4 Drunkenness
Finished drinking 4 rockin' wagon.
Since you are not in a Moxie sign, you may not visit the brewery.
(usable quantity of black & tan is limited to 0 by inebriety)
Since you are not in a Moxie sign, you may not visit the brewery.
(usable quantity of shot of blackberry schnapps is limited to 0 by inebriety)

Of course, this is a flagrant case of user error, but I tried to look at UseItemRequest.java, and it looked like the code should handle this sort of case.

I was wrong apparently: allowBoozeConsumption() on line 981 handles the overdrinking warning, but the warning only happens if the player has pvp attacks or adventures left.

I don't know if this code pre-dates the CLI and ASH overdrink functions, but since there is a way for scripts to get around the warning, could we change line 1030 of UseItemRequest.java to:
PHP:
if ( !InputFieldUtilities.confirm( "Are you sure you want to overdrink?" ) )
 

Theraze

Active member
A quick and easy solution for this would be to just use the eatdrink.ash script... Since there, you put what your target appetite/inebriety/spleen are, whether or not overdrinking is allowed, and just let it run... I run with 3 aliases myself, one for appetite/spleen (no drinking), one for all 3, and one for the end of the day with all 3 and overdrinking. Simple, and you never overdrink on accident.
 

lostcalpolydude

Developer
Staff member
Maybe if there is unused liver space before you overdrink, there could be a prompt. If you're at 14/14 or 19/19 drunk and have 0 turns left, there should not be a prompt.
 

slyz

Developer
I disagree, I feel this would be more annoying than anything else.

Maybe I didn't explain clearly the change I'm proposing. What is annoying about it? I just want the behavior to be the same, whether I have adventures left or not. Any script that wants to overdrink without the prompt should already be using the overdrink command already.

A quick and easy solution for this would be to just use the eatdrink.ash script.
What does EatDrink.ash have to do with this? I can't tell EatDrink.ash what I want to eat and drink.

EDIT: I was about to edit to add what lost just said, he ninja'd my edit! Although maybe fullness and spleen should be checked for room too.
 
Last edited:

heeheehee

Developer
Staff member
Personally, I'd modify it so that it only assumes overdrinking is authorized with 0 adventures, full stomach/liver. Possibly spleen, as well, but that might get annoying in HC if the character in question doesn't have a spleen familiar.

(partly what lost said, but extended. Which is what slyz added.)
 

slyz

Developer
I think I finally understood what would be annoying: the confirmation pop-up when using the consumption manager!
More often then not, I bank adventures when I'm on a run, so I'm used to that pop-up already. Is it really that annoying? Is the benefit from extending Mafia's protection from accidental overdrinking to the cases where you can still generate adventures not worth it?
 
Top