Feature - Implemented CLI command for using Divine Flute to drink a booze

Terion

Member
Something like "flute [#] booze" which causes it to use a divine champagne flute and then choose the indicated booze from the following dropdown (and repeat if there's a multiple quantitiy.) It should probably go through the normal checks for over-drink warnings. You could even have overflute, to mirror the overdrink command.

Very minor priority, but my alt (who uses up extraneous MP on Divine summonings) always has flutes lying around, and they're so cheap (mall minimum, I think) he tends to use one for his nightcap; currently I have to do it through the relay browser, and it would be convenient to have a CLI command I could use or script.

If this already exists, point me to it and disregard this request, thanks. ;)
 

Veracity

Developer
Staff member
You can do it through the item manager, so you don't "have to do it through the relay browser".
Right off hand, I can't think of a CLI equivalent.
 

heeheehee

Developer
Staff member
It's a bit odd, but Mafia consumes consumption helpers (namely flutes, mugs, and forks) as if they were actual booze/foods. So... in the CLI: "drink divine champagne flute; drink gimlet" or whatever your drink is. You could even alias it: "alias flute => drink divine champagne flute; drink %%".

If you want an integer input as well, that starts to get a bit tricky, and would require some ASH nonsense.
"alias flute => ash matcher m = create_matcher("(\\d+) (.*)", "%%"); int qty = 1; item filler; if(!m.find()) filler = "%%".to_item(); else {qty = m.group(1).to_int(); filler = m.group(2).to_item();} drink(qty, $item[divine champagne flute]); drink(qty, filler);"

(and all sorts of random nonsense like that. At least, I think that'd work. Haven't actually tried it yet.)

(edit: fixed, I think)
 
Last edited:

Terion

Member
Ah, "drinking" a helper causing that helper to get cued up for the next drink takes care of it. Thanks, hee3; that alias worked fine. (I'm not worried about the integer input, so I'm going to stay away from that ash chaos.

Feel free to close this request. :D
 

heeheehee

Developer
Staff member
Fair enough, the ASH nonsense had several errors either way, so it wouldn't have worked (just fixed, though).
 
Top