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

◆ HasInternalExclusionConflicts()

bool Entity::HasInternalExclusionConflicts ( int targetSlot)
inlineprivate

checks if any attachment or item state would interfere with this being attached into a different slot (Headgear -> Mask)

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

4482 {
4483 set<int> targetSlotValues = GetAttachmentExclusionMaskSlot(targetSlot);
4484 if (targetSlotValues) //can be null, if so, no conflict
4485 {
4486 set<int> additionalValues = new set<int>(); //NOT slot values
4487 additionalValues.InsertSet(GetAttachmentExclusionMaskGlobal());
4488 additionalValues.InsertSet(GetAttachmentExclusionMaskChildren());
4489
4490 if (additionalValues.Count() > 0)
4491 {
4492 int countTarget = targetSlotValues.Count();
4493 for (int i = 0; i < countTarget; i++)
4494 {
4495 if (additionalValues.Find(targetSlotValues[i]) != -1)
4496 {
4497 return true;
4498 }
4499 }
4500 }
4501 }
4502 return false;
4503 }
set< int > GetAttachmentExclusionMaskSlot(int slotId)
Specific slot behavior.
Определения EntityAI.c:4463
set< int > GetAttachmentExclusionMaskGlobal()
Global mask value, independent of slot-specific behavior!
Определения EntityAI.c:4469
set< int > GetAttachmentExclusionMaskChildren()
Mask value coming from the item's attachments.
Определения EntityAI.c:4475

Перекрестные ссылки GetAttachmentExclusionMaskChildren(), GetAttachmentExclusionMaskGlobal() и GetAttachmentExclusionMaskSlot().