Cocktail Maximizer 1.0.6 (requires zlib)
Have Superhuman Cocktailcrafting and a bunch of ingredients? Don't know how to make the most drinks out of all your stuff? Not sure what to use your still charges for?
Enter the Cocktailcrafting Maximizer. The script will run a linear program to determine how to maximize your still uses and what drinks to create. It will try to first maximize the total number of drinks you can make, breaking ties by total profit. It will consider the following variables:
For example, here are results when I ran the script with my current inventory:
The script won't actually do anything when you run it. You'll have to create the drinks yourself.
As a note, sometimes it will tell you to make 0.5 of something, for example:
This is caused when you will have one upgrade in the still left, so the algorithm tries to make 1/2 of a drink. In that case you would just upgrade one of the two ingredients and not build half a cocktail. I'm not going to correct for that, because integer programming is much, much more difficult than linear programming.
To download, run this in your CLI:
Changelog:
1.0.1 Initial release
1.0.3 Fixed bug where raspberries were called strawberries
1.0.4 Made output prettier so you can figure out when it tells you to make 0.5 of something. Also the code is actually readable, maybe
1.0.5 Teqiwila slammer displays correctly
1.0.6 Migrated to SVN
Have Superhuman Cocktailcrafting and a bunch of ingredients? Don't know how to make the most drinks out of all your stuff? Not sure what to use your still charges for?
Enter the Cocktailcrafting Maximizer. The script will run a linear program to determine how to maximize your still uses and what drinks to create. It will try to first maximize the total number of drinks you can make, breaking ties by total profit. It will consider the following variables:
- Number of "upgraded" booze bottles you own
- Number of "upgraded" mixers you own
- Number of garnishes you own
- Number of charges in Nash Crosby's Still you have today
- Number of base booze bottles / base mixers you own (plus, the price of ones you can buy) to upgrade in the Still
- Price of resulting drinks
For example, here are results when I ran the script with my current inventory:
Code:
Prep work:
upgrade 5 olives to cocktail onions
buy 5 soda waters; upgrade 5 soda waters to tonic waters
Crafting:
craft 6x Neuromancer from 6x Calcutta Emerald + 6x cocktail onion + 6x coconut shell
craft 1x Mon Tiki from 1x Lieutenant Freeman + 1x kiwi + 1x coconut shell
craft 6x yellow brick road from 1x Definit + 1x tonic water + 1x little paper umbrella
craft 1x tangarita from 1x Jorge Sinsonte + 1x tangerine + 1x magical ice cubes
craft 1x Mae West from 1x Domesticated Turkey + 1x raspberry + 1x magical ice cubes
Total drinks: 15
Estimated profit: 87074
The script won't actually do anything when you run it. You'll have to create the drinks yourself.
As a note, sometimes it will tell you to make 0.5 of something, for example:
Code:
Prep work:
buy 4.5 soda waters; upgrade 4.5 soda waters to tonic waters
upgrade 1 strawberries to raspberries
upgrade 4.5 vodka to Definit
Crafting:
craft 4.5x yellow brick road from 4.5x Definit + 4.5x tonic water + 4.5x little paper umbrella
craft 1x prussian cathouse from 1x Champagne + 1x raspberry + 1x magical ice cubes
Total drinks: 5.5
Estimated profit: 32312
This is caused when you will have one upgrade in the still left, so the algorithm tries to make 1/2 of a drink. In that case you would just upgrade one of the two ingredients and not build half a cocktail. I'm not going to correct for that, because integer programming is much, much more difficult than linear programming.
To download, run this in your CLI:
Code:
svn checkout http://svn.code.sf.net/p/rlbond86-mafia-scripts/code/cocktailmax/trunk
Changelog:
1.0.1 Initial release
1.0.3 Fixed bug where raspberries were called strawberries
1.0.4 Made output prettier so you can figure out when it tells you to make 0.5 of something. Also the code is actually readable, maybe
1.0.5 Teqiwila slammer displays correctly
1.0.6 Migrated to SVN
Last edited: