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

◆ IsCargoInHiearchy()

bool GameInventory::IsCargoInHiearchy ( )
inlineprotected

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

См. определение в файле 3_Game/DayZ/Systems/Inventory/Inventory.c строка 423

424 {
425 InventoryLocation lcn = new InventoryLocation();
427 while (ent)
428 {
429 if (ent.GetInventory().GetCurrentInventoryLocation(lcn) && lcn.IsValid())
430 {
431 if (lcn.GetType() == InventoryLocationType.CARGO || lcn.GetType() == InventoryLocationType.PROXYCARGO)
432 return true;
433 }
434
435 ent = ent.GetHierarchyParent();
436 }
437
438 return false;
439 }
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().