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

◆ DestroyMaterialsServer()

void DestroyMaterialsServer ( Man player,
string part_name )
protected

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

1198 {
1199 ConstructionPart part = GetConstructionPart(part_name);
1201 foreach (ConstructionMaterialData dta : materials)
1202 {
1203 //get material
1204 ItemBase attachment = ItemBase.Cast(m_EntityParent.FindAttachmentBySlotName(dta.m_MaterialSlotName));
1205 if (!attachment)
1206 continue;
1207
1208 //material still attached
1209 if (dta.m_MaterialLockable)
1210 {
1211 InventoryLocation invloc = new InventoryLocation();
1212 attachment.GetInventory().GetCurrentInventoryLocation(invloc);
1213 if (LogManager.IsBaseBuildingLogEnable()) bsbDebugPrint("[bsb] " + Object.GetDebugName(m_EntityParent) + " DestroyMaterialsServer unlock slot=" + invloc.GetSlot());
1214
1215 m_EntityParent.GetInventory().SetSlotLock(invloc.GetSlot() , false);
1216 g_Game.ObjectDelete(attachment);
1217 }
1218 }
1219 }
ConstructionPart GetConstructionPart()
Определения ActionPartInfo.c:235
class BaseBuildingBase extends ItemBase bsbDebugPrint(string s)
Определения BaseBuildingBase.c:1291
EntityAI m_EntityParent
Определения ConstructionBase.c:45
DayZGame g_Game
Определения DayZGame.c:4074
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(), g_Game, GetConstructionPart(), ConstructionPart::GetMaterialsData(), InventoryLocation::GetSlot(), LogManager::IsBaseBuildingLogEnable() и m_EntityParent.

Используется в DestroyPartServer().