My spleen use: Difference between revisions

From Kolmafia
Jump to navigation Jump to search
imported>StDoodle
mNo edit summary
imported>Heeheehee
m Server hits are bad, mmkay?
Line 21: Line 21:
code=
code=
<syntaxhighlight>
<syntaxhighlight>
while (my_spleen_use() < spleen_limit()) {
if (my_spleen_use() < spleen_limit()) {
   retrieve_item(1 , $item[twinkly wad]);
   retrieve_item(spleen_limit()-my_spleen_use() , $item[twinkly wad]);
   use(1 , $item[twinkly wad]);
   use(spleen_limit()-my_spleen_use() , $item[twinkly wad]);
}
}
</syntaxhighlight>}}|
</syntaxhighlight>}}|

Revision as of 04:18, 26 April 2010

Function Syntax

int my_spleen_use()

Returns the number of spleen hits your character has taken this KoL day.

Code Sample

Buy and use twinkly wads as many times as possible.

if (my_spleen_use() < spleen_limit()) {
   retrieve_item(spleen_limit()-my_spleen_use() , $item[twinkly wad]);
   use(spleen_limit()-my_spleen_use() , $item[twinkly wad]);
}

See Also

spleen_limit() | retrieve_item() | use()