Put closet: Difference between revisions
Jump to navigation
Jump to search
imported>Bale add code |
imported>Bale mNo edit summary |
||
Line 5: | Line 5: | ||
FunctionPage| | FunctionPage| | ||
name={{#var:name}}| | name={{#var:name}}| | ||
function1={{Function| | function1={{Function| | ||
Line 42: | Line 41: | ||
cli_equiv=The CLI command "closet" with the parameter "put" works similarly. | cli_equiv=The CLI command "closet" with the parameter "put" works similarly. | ||
}} | }} | ||
[[Category:Item Management]] |
Latest revision as of 22:02, 21 May 2010
Function Syntax
boolean put_closet(int qty ,item it )
- qty is the quantity to move
- it is the item to move
Attempts to move qty of it to your Colossal Closet from your main inventory. Returns true if the move succeeds and false if it does not.
The one parameter version without it will move meat instead of items.
Code Sample
Closets meat so that you only have 5,000 meat on hand.
if(my_meat() > 5000)
put_closet(my_meat() - 5000);
CLI Equivalent
The CLI command "closet" with the parameter "put" works similarly.