returns how many of a type/id exists in the inventory
| 1418 | |
| 1419 | // returns how many of a type/id exists in the inventory |
| 1420 | int Inventory::GetTypeIDCount(int type, int id) { |
| 1421 | inven_item *node = FindItem(type, id); |
| 1422 | |
| 1423 | if (!node) |
| 1424 | return 0; |
| 1425 | if (node->flags & INVF_OBJECT) { |
| 1426 | return 1; |
| 1427 | } |
| 1428 | |
| 1429 | return node->count; |
| 1430 | } |
| 1431 | |
| 1432 | // determines whether the position is selectable |
| 1433 | bool Inventory::IsSelectable(void) { |
no outgoing calls
no test coverage detected