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

◆ SetLockOnAttachedMaterials()

void SetLockOnAttachedMaterials ( string part_name,
bool lock_slot )
protected

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

1384 {
1385 ConstructionPart part = GetConstructionPart(part_name);
1387 foreach (ConstructionMaterialData dta : materials)
1388 {
1389 ItemBase attachment = ItemBase.Cast(m_EntityParent.FindAttachmentBySlotName(dta.m_MaterialSlotName));
1390 if (attachment && dta.m_MaterialLockable)
1391 {
1392 InventoryLocation inventoryLocation = new InventoryLocation();
1393 attachment.GetInventory().GetCurrentInventoryLocation(inventoryLocation);
1394 m_EntityParent.GetInventory().SetSlotLock(inventoryLocation.GetSlot(), lock_slot);
1395
1396 if (LogManager.IsBaseBuildingLogEnable()) bsbDebugPrint("[bsb] " + Object.GetDebugName(m_EntityParent) + " SetLockOnAttachedMaterials lock=" + lock_slot +" slot=" + inventoryLocation.GetSlot());
1397 }
1398 }
1399 }
ConstructionPart GetConstructionPart()
Определения ActionPartInfo.c:235
class BaseBuildingBase extends ItemBase bsbDebugPrint(string s)
Определения BaseBuildingBase.c:1291
EntityAI m_EntityParent
Определения ConstructionBase.c:45
instanced data holder for single construction material
Определения ConstructionMaterials.c:3
array< ref ConstructionMaterialData > GetMaterialsData()
Определения ConstructionPart.c:346
Instanced construction part data classes for dynamic data, statics now stored on EntityType level in ...
Определения ConstructionPart.c:4
proto native int GetSlot()
returns slot id if current type is Attachment
InventoryLocation.
Определения InventoryLocation.c:30
static bool IsBaseBuildingLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:809
Определения ObjectTyped.c:2
Result for an object found in CGame.IsBoxCollidingGeometryProxy.

Перекрестные ссылки bsbDebugPrint(), GetConstructionPart(), ConstructionPart::GetMaterialsData(), InventoryLocation::GetSlot(), LogManager::IsBaseBuildingLogEnable() и m_EntityParent.

Используется в Rebuilding::SetPartStateLocal().