Storage amount
Jump to navigation
Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Function Syntax
- it is the item to check
Returns the amount of the given item that are in storage at Hagnk's.
Code Sample
The following code will check a pull list loaded from a text file.
int day = 2;
int [int, item] static_pulls; //Items that are always included in a pull list.
file_to_map( "static_pulls.txt" , static_pulls );
//Validate your pull list before you begin the day
foreach it, req_num in static_pulls[ day ]
{
if ( storage_amount( it ) < req_num )
print( "Uh-oh! You don't have enough of " + it + " to pull." , "red" );
else
print( "You have enough " + it );
}
Note that take_storage() returns a boolean value indicating whether an attempt at pulling was successful.
See Also
closet_amount() | display_amount() | equipped_amount() | item_amount() | shop_amount() | stash_amount()
More Information
Information on handling free pulls is at Tips, Tricks and Workarounds.