Difference between revisions of "CInventory::isInInventory"

From King Arthur's Gold Wiki
Jump to: navigation, search
(Created page with "<onlyinclude> Checks if the given CBlob exists in this inventory, either by CBlob reference or by name. </onlyinclude> This method has two variants. The first variant c...")
 
(No difference)

Latest revision as of 20:58, 19 August 2012

Checks if the given CBlob exists in this inventory, either by CBlob reference or by name.


This method has two variants.

The first variant checks if the given CBlob is in inventory, returning true if the CBlob is there, otherwise returning false.

bool isInInventory(CBlob@ blob)

The second variant looks for CBlobs with the given name in this inventory, counts them up and returns true if there are at least as many as the number specified by the quantity argument, otherwise false.

bool isInInventory(const string &blobName, int quantity)

Object method of: CInventory