Returns the number of items in cargo, otherwise returns 0(non-cargo objects). Recursive.
См. определение в файле ItemBase.c строка 3520
3521 {
3522 int item_count = 0;
3524
3525 if (GetInventory().GetCargo() != NULL)
3526 {
3527 item_count = GetInventory().GetCargo().GetItemCount();
3528 }
3529
3530 for (int i = 0; i < GetInventory().AttachmentCount(); i++)
3531 {
3532 Class.CastTo(item,GetInventory().GetAttachmentFromIndex(i));
3533 if (item)
3534 item_count += item.GetNumberOfItems();
3535 }
3536 return item_count;
3537 }
Перекрестные ссылки Class::CastTo() и ItemBase().