void main( string thing )
{
item wanted;
if ( thing.contains_text( "acc" ) )
{
#wanted = $item[stolen accordion];
print_html( "you want a toy accordion" );
return;
}
else if ( thing.contains_text( "totem" ) )
{
wanted = $item[turtle totem];
}
else if ( thing.contains_text( "saucepan" ) )
{
wanted = $item[saucepan];
}
else
{
abort("not a valid item");
}
while ( item_amount( wanted ) < 1 )
{
use( 1, $item[chewing gum on a string] );
}
}
unfortunately neither acquire, nor create work for getting a turtle totem.Doesn't "create turtle totem" work?
Or perhaps even "acquire turtle totem". The Hermit is a Coinmaster with a worthless item as the currency, I've seen (written) the code to use chewing gum to get worthless items.
There is not. I use
to get buff-casting items.Code:void main( string thing ) { item wanted; if ( thing.contains_text( "acc" ) ) { #wanted = $item[stolen accordion]; print_html( "you want a toy accordion" ); return; } else if ( thing.contains_text( "totem" ) ) { wanted = $item[turtle totem]; } else if ( thing.contains_text( "saucepan" ) ) { wanted = $item[saucepan]; } else { abort("not a valid item"); } while ( item_amount( wanted ) < 1 ) { use( 1, $item[chewing gum on a string] ); } }
That is a good idea.We could make a creation method - SEWER - which consists of repeatedly using chewing gum on a string until you get the item.
There is not. I use
void main()
{
// using chewing gum on a string to fish for a turtle totem
while ( item_amount( $item[turtle totem] ) < 1 )
{
use( 1, $item[chewing gum on a string] );
}
// using chewing gum on a string to fish for a saucepan
while ( item_amount( $item[saucepan] ) < 1 )
{
use( 1, $item[chewing gum on a string] );
}
// accordion thieves are the only ones who can use stolen accordion, and they start out with one, so fishing for it is pointless.
// Instead, if any other class, should grab a toy accordion.
if (my_class() != $class[Accordion Thief])
{
if ( item_amount( $item[toy accordion] ) < 1 )
{
buy(1, $item[toy accordion]);
}
}
}
Oh hey, sorry for the delayed response. Anyways, thank you.The main issue there is that toy accordion is a waste of meat if you will soon be buying an antique accordion. And with meat being tight early on day 1, and a saucepan not really being needed for a while usually (compared to a turtle totem being useful on turn 0), that code wouldn't be very useful for me. But if it works for you (perhaps due to pulling something to autosell for early meat), then that's great.
awesome. thank you.Revision 18951 adds a creation method for sewer items.
acquire turtle totem - will go to the sewer to fish one out, if not already in inventory
acquire 10 worthless item - will ensure that you have 10 worthless items in inventory, going fishing if necessary
You can also use create to force retrieval, regardless of how many you have in inventory
create 3 turtle totem - will get you 3 more turtle totems
Note that "acquire" will use all valid (per preferences) item sources, but create always goes fishing.
Which is generally true, for acquire vs. create