DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ IsCargoInHiearchy()

bool GameInventory::IsCargoInHiearchy ( )
inlineprotected

Returns true if inventory owner or his hiearchy parents are in cargo.

См. определение в файле Inventory.c строка 421

422 {
423 InventoryLocation lcn = new InventoryLocation();
425 while (ent)
426 {
427 if (ent.GetInventory().GetCurrentInventoryLocation(lcn) && lcn.IsValid())
428 {
429 if (lcn.GetType() == InventoryLocationType.CARGO || lcn.GetType() == InventoryLocationType.PROXYCARGO)
430 return true;
431 }
432
433 ent = ent.GetHierarchyParent();
434 }
435
436 return false;
437 }
class LogManager EntityAI
InventoryLocationType
types of Inventory Location
Определения InventoryLocation.c:4
proto native EntityAI GetInventoryOwner()
Engine native functions.
proto native bool IsValid()
verify current set inventory location
proto native int GetType()
returns type of InventoryLocation

Перекрестные ссылки GetInventoryOwner(), InventoryLocation::GetType() и InventoryLocation::IsValid().