From Kolmafia
(Difference between pages)
Jump to navigation
Jump to search
imported>Relyk |
|
Line 1: |
Line 1: |
− | {{
| + | Terminal => Run Build Task... |
− | #vardefine:name|chew}}{{
| |
− | #vardefine:return_type|boolean}}{{
| |
− | | |
− | FunctionPage|
| |
− | name={{#var:name}}|
| |
− | | |
− | function1={{Function|
| |
− | name={{#var:name}}|
| |
− | aggregate={{#var:aggregate}}|
| |
− | return_type={{#var:return_type}}|
| |
− | return_also={{#var:return_also}}|
| |
− | parameter1={{Param|int|qty}}|
| |
− | parameter2={{Param|item|consume}}|
| |
− | p1desc={{Pspan|qty}} is the quantity to chew|
| |
− | p2desc={{Pspan|consume}} is the item to chew|
| |
− | }}|
| |
− | | |
− | function_description=Will attempt to chew {{pspan|qty}} amount of item {{pspan|consume}}. Returns true for chewable items and false for items that are not. (The return value does not reflect whether or not the items were actually consumed.)|
| |
− | | |
− | code1={{CodeSample|
| |
− | title=Code Sample|
| |
− | description=Chew as many coffee pixie sticks as possible.|
| |
− | code=
| |
− | <syntaxhighlight>
| |
− | item it = $item[coffee pixie stick];
| |
− | int spleenUsed = it.spleen;
| |
− | int amount = (spleen_limit() - my_spleen_use()) / spleenUsed;
| |
− | chew(amount, it);
| |
− | </syntaxhighlight>
| |
− | }}|
| |
− | | |
− | see_also={{SeeAlso|eat|drink}}|
| |
− | cli_equiv=The CLI command "chew" works similarly.|
| |
− | }}
| |
− | | |
− | [[Category:Item Management]]
| |
Latest revision as of 05:17, 22 December 2020
Terminal => Run Build Task...