//returns true if you have item in inventory or equiped
//does not unequip
//$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
boolean haveItem(item thingy)
{
if(item_amount(thingy)>0)
return true;
if(have_equipped( thingy ))
return true;
return false;
}
// Identify Dusty Bottles
//$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
// Return true if you are cabable of identifing the wine bottles
boolean WineIdentifable()
{
if (!haveItem($item[Lord Spookyraven's spectacles]))
return false;
if (my_ascensions( )!= get_property("lastDustyBottleReset").to_int())
{
cli_execute("dusty");
if (my_ascensions( )!= get_property("lastDustyBottleReset").to_int())
return false;
}
return true;
}
// Returns Dusty bottle based on what type you are asking for:
// 1= Average wine
// 2= Vinger wine
// 3= Spooky wine (Kiss of the Black Fairy)
// 4= Great wine
// 5= Glassy wine
// 6= Bad wine
item Dusty(int Type)
{
if (!WineIdentifable())
return $item[none];
switch
{
case get_property ("lastDustyBottle2271").to_int()==Type :
return to_item(2271);
case get_property ("lastDustyBottle2272").to_int()==Type :
return to_item(2272);
case get_property ("lastDustyBottle2273").to_int()==Type :
return to_item(2273);
case get_property ("lastDustyBottle2274").to_int()==Type :
return to_item(2274);
case get_property ("lastDustyBottle2275").to_int()==Type :
return to_item(2275);
case get_property ("lastDustyBottle2276").to_int()==Type :
return to_item(2276);
}
return $item[none];
}
//Drinks x number of your best dusty wine
boolean DrinkBestDusty(int howmany)
{
if(drink( howmany, Dusty(4) ))
return true;
else
return false;
}