Super Advanced Cocktailcrafting

grazepoop

New member
This is a script I've made to see if I could, and to handle some of what I feel is a bit tedious. Maybe most/all of this is redundant, but it was fun, and I learned a lot.

It casts 5 Cocktailcrafting, adventures for the appropriate booze (I prefer that to shopping. Could be used hardcore?), buys the fruit and makes the superadvanced cocktails with the still. Only the pure stat gaining ones. None of the half/half ones. Just a preference.

I'm aware that I probably don't need to buy the fruit.

Also, it doesn't work properly if you have any cubes, umbrellas or shells to start off with. And I can't confirm what happens if you've used the still already.

I'm working on adding the capability of taking any extra cubes, etc. and adventuring for the booze and making normal advanced cocktails with them.

Grazepoop
 

Attachments

  • SuperAdvancedBooze.ash
    3 KB · Views: 128

grazepoop

New member
I improved the script a bit.

If I recall correctly, things weren't working perfectly and it bought a drink on me, but it is better now.

Just a fun project for me.
 

Attachments

  • SuperAdvancedBooze.ash
    3.5 KB · Views: 121

etheralled

New member
OMG TY I actually understood the bulk of that and am gonna work on making one for my tiny plastic swords. Yes theres more optimal drinks these day, but dang I like them TPS drinks. LOL.

You guys are a really bad influence on me. LMAO ;D
 

w0rm

New member
On a related topic, I recently wrote a bit of script so that my clan's buffbots could create mixers for superhuman cocktails out of any bits they had lying around in their inventory. In case this is of interest to anyone, here it is. If nothing else, the map of superhuman cocktail ingredients might be of use in other scripts.


void main ()
{

item [item] superbooze;

superbooze [$item[bottle of gin]] = $item[bottle of Calcutta Emerald];
superbooze [$item[bottle of rum]] = $item[bottle of Lieutenant Freeman];
superbooze [$item[bottle of tequila]] = $item[bottle of Jorge Sinsonte];
superbooze [$item[bottle of vodka]] = $item[bottle of Definit];
superbooze [$item[bottle of whiskey]] = $item[bottle of Domesticated Turkey];
superbooze [$item[boxed wine]] = $item[Boxed Champagne];

superbooze [$item[grapefruit]] = $item[tangerine];
superbooze [$item[lemon]] = $item[kiwi];
superbooze [$item[olive]] = $item[cocktail onion];
superbooze [$item[orange]] = $item[kumquat];
superbooze [$item[soda water]] = $item[tonic water];
superbooze [$item[strawberry]] = $item[raspberry];

int count_still;
count_still = 10;

int mixers;

foreach basic in superbooze
{
mixers=item_amount(basic);
if (mixers>count_still) {mixers = count_still;}
create (mixers, superbooze [basic]);
count_still = count_still-mixers;
}

}
 

izchak

Member
A fair while back, I wrote this little function to utilize the still on a daily basis. I haven't used it for ages, but I think it still works.
As an interesting demonstration of parallel evolution in action, w0rms code is very similar to mine, only neater!
Mine has the advantage of buying soda water when all other options fail, though. Oh, and I check that you can actually use the still, just to be safe.

EDIT: Just because, I cleaned my version up a little, to be more flexible

Code:
# this tries to use the still, improving whatever you have that can be improved
boolean utilize_still(){
	if(my_primestat() != $stat[moxie]) {
		print("youre not a moxie class, and hence cannot use the still");
		return false;
	}
	if(stills_available() == 0) {
		print("you have no uses left at the still");
		return false;
	}
	item [item] spirits_n_mixers;
	spirits_n_mixers[ $item[grapefruit] ] = $item[tangerine];
	spirits_n_mixers[ $item[lemon] ] = $item[kiwi];
	spirits_n_mixers[ $item[olive] ] = $item[cocktail onion];
	spirits_n_mixers[ $item[orange] ] = $item[kumquat];
	spirits_n_mixers[ $item[soda water] ] = $item[tonic water];
	spirits_n_mixers[ $item[strawberry] ] = $item[raspberry];
	spirits_n_mixers[ $item[bottle of gin] ] = $item[bottle of Calcutta Emerald];
	spirits_n_mixers[ $item[bottle of rum] ] = $item[bottle of Lieutenant Freeman];
	spirits_n_mixers[ $item[bottle of tequila] ] = $item[bottle of Jorge Sinsonte];
	spirits_n_mixers[ $item[bottle of vodka] ] = $item[bottle of Definit];
	spirits_n_mixers[ $item[bottle of whiskey] ] = $item[bottle of Domesticated Turkey];
	spirits_n_mixers[ $item[boxed wine] ] = $item[boxed champagne];

	print("checking spirits, mixers, and crosby nash's still...");
	foreach key in spirits_n_mixers {
		if( item_amount( key ) > 0 ) {
			print( "hey, you have " + item_amount(key) + " " + key );
			print( "you have " + stills_available() + " uses left at the still");
			print( "making " + item_amount( key ) + " " + spirits_n_mixers[key]);
			create(item_amount( key ), spirits_n_mixers[key]);
			if(stills_available() == 0) return true;
		}
	}
	print("hmm, you didnt have much, so I made " + stills_available() + " tonic waters");
	buy (stills_available(), $item[soda water]);
	return create(stills_available(), $item[tonic water]);
}
 

Lupychica

New member
There is a function called creatable_amount that you can use with each type of the SHC drinks. This is a snippet of how I use it for characters with liver of steel.

Code:
int amount = creatable_amount(drink);
if(amount >= 5)
{		
  item drink = string_to_item( "Mon Tiki" ); 	  
  boolean created = create(5, drink);
  boolean drunk = drink(4, drink); 
}
 

tebee

Member
I published another script in which I used a modified version of this script to make drinks every day. Now the original script has problems if you have too many of the cocktailcrafting accessories in stock so I put a check in to move the excess to the closet, I also put a check in so you could run this from any id , even one that had superadvanced cocktailcrafting but no access to the still and it would not bomb out, just return without doing anything so it could be put in a daily script.

I've had a couple more suggestions for improvement which I've incorporated now so I though you might like to see the final script. It still overbuys in certain circumstances but should even out in the long run, my version automaticly sells the drinks in the mall but that's commented out in this version .

Tom
 

Attachments

  • scdrinks2.ash
    4.9 KB · Views: 126
Top