How can I tell if I have "smart skull" in my inventory?

kadan

New member
that's about it for now :)

It's part of a make bartender-in-the-box idea I have.

If !skull or !disembodied brain exists
{
if !disembodied clover exists
{
sewer dive for trinket
get clover from hermit
if !disembodied clover exists
{
mallbuy 1 clover
}
}
use clover
adventure plains:cemetary post-crypt
}
if !box exists
mallbuy 1 box

if !spring exists
mallbuy 1 spring

if beer lens count < 2
adventure woods:tavern post-quest for beer lens

if meat past count < 10
make 10 meat paste

if !cocktailcrafting kit
mallbuy cocktailcrafting kit @ 500

make bartender-in-the-box
 
Last edited:

Grotfang

Developer
I'm sure there's a better way to do this, and I will point out this hasn't even been verified (so might now work), but I threw this together.

I think it will do what you are describing (but please, please bear in mind it was written in less than 5 minutes in the forums reply box - I do not claim it works!)

Code:
item [int] item_buy;
item_buy[0] = $item[box];
item_buy[1] = $item[spring];
item_buy[2] = $item[cocktailcrafting kit];

if( item_amount( $item[disembodied brain] ) == 0 || item_amount( $item[smart skull] ) == 0 )
{
    if( item_amount( $item[ten-leaf clover] ) == 0 && item_amount( $item[disassembled clover] ) == 0 )
    {
        while( item_amount( $item[worthless trinket] ) == 0 || item_amount( $item[worthless gewgaw] ) == 0 || item_amount( $item[worthless knick-knack] ) == 0 )
        {
            adventure( 1 , $location[unlucky sewer] );
        }
        hermit( 1 , $item[ten-leaf clover] );
    }
    if( item_amount( $item[ten-leaf clover] ) == 0
    {
        use( 1 , $item[ten-leaf clover] );
    }
    adventure( 1 , $location[Post-Cyrpt Cemetary] );
}
foreach int in item_buy
{
    if( item_amount( item_buy[int] ) == 0 )
    {
        buy( 1 , item_buy[int] );
    }
}
if( item_amount( $item[meat paste] ) < 10 )
{
    create( 10 - item_amount( $item[meat paste] ) , $item[meat paste] );
}
if( item_amount( $item[beer goggles] ) == 0 )
{
    while( item_amount( $item[beer lens] ) < 2 )
    {
        adventure( 1 , $location[Typical Tavern] );
    }
    create( 1 , $item[beer goggles] );
}
create( 1 , $item[Bartender-in-the-box] );
##If you want to install in the campsite too, uncomment the line below
##use( 1 , $item[Bartender-in-the-box] );
 
Last edited:

Spiny

Member
The main problem that I foresee with the whipped together script above is in the instance of the hermit not having clovers on a given day or not getting beer lenses before getting falling down drunk. I don't know what level character is being used for this, but I would think that acquiring 31337 scrolls from Orc chasm would be better than sewering/randomly checking hermit. That would satisfy getting worthless items and clovers.

Edit: The cli command to find out if you have a smart skull would be
Code:
inv smart skull
 

Grotfang

Developer
The main problem that I foresee with the whipped together script above is in the instance of the hermit not having clovers on a given day or not getting beer lenses before getting falling down drunk. I don't know what level character is being used for this, but I would think that acquiring 31337 scrolls from Orc chasm would be better than sewering/randomly checking hermit. That would satisfy getting worthless items and clovers.

My script was an attempt simply to put into ASH what the OP had presented in pseudo-code. I would question whether a smart skull and disembodied brain are really worth a clover... The price of a brainy skull is only ~300 meat more than the clover, and your adventures are worth something. Even if you are lucky and get the worthless doo-dah first turn, most people's turns would value at more than 300 in my opinion. Even if it breaks even, why not go the simpler route and just buy the skull?

This script also doesn't deal with running out of adventures, or even run any basic checks to see if you have any assembled components. Oh, and don't forget it also won't know what's going on if the post-cyrpt cemetery isn't open yet, if the faucet hasn't been dealt with and, of course, my error in the line:

Code:
if( item_amount( $item[ten-leaf clover] ) == 0
    {
        use( 1 , $item[ten-leaf clover] );
    }

Which is both broken in not having a closing parentheses and also should read:

Code:
if( item_amount( $item[ten-leaf clover] ) == 0 )
    {
        use( 1 , $item[disassembled clover] );
    }

As an example of code showing what you were asking, I think it's ok. However, I wouldn't use it ;)
 
Top