CInventory::isInInventory

From King Arthur's Gold Wiki
Revision as of 21:58, 19 August 2012 by Shadlington (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

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