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

◆ ProcessItemsWetness()

void ProcessItemsWetness ( array< int > pSlotIds)
protected

Soak items at specific Slot ID(s)

Аргументы
pSlotIdsInventory Slot IDs to process

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

695 {
696 EntityAI attachment;
697
698 int playerAttachmentCount = m_Player.GetInventory().AttachmentCount();
699
700 #ifdef ENABLE_LOGGING
701 LogDryWetProcess(string.Format("Environment :: ProcessItemsWetness (update interval=%1s)", GameConstants.ENVIRO_TICK_RATE));
702 #endif
703 for (int attIdx = 0; attIdx < playerAttachmentCount; ++attIdx)
704 {
705 attachment = m_Player.GetInventory().GetAttachmentFromIndex(attIdx);
706 if (attachment.IsItemBase())
707 {
708 int attachmentSlotsCount = attachment.GetInventory().GetSlotIdCount();
709 for (int attachmentSlotId = 0; attachmentSlotId < attachmentSlotsCount; ++attachmentSlotId)
710 {
711 int attachmentSlot = attachment.GetInventory().GetSlotId(attachmentSlotId);
712 for (int i = 0; i < pSlotIds.Count(); ++i)
713 {
714 if (attachmentSlot == pSlotIds.Get(i))
715 {
716 ApplyWetnessToItem(ItemBase.Cast(attachment));
717 break;
718 }
719 }
720 }
721 }
722 }
723
724 if (m_Player.GetItemInHands())
725 ApplyWetnessToItem(m_Player.GetItemInHands());
726
727 #ifdef ENABLE_LOGGING
728 LogDryWetProcess("==========");
729 #endif
730 }
void ApplyWetnessToItem(ItemBase pItem)
Определения Environment.c:732
DayZPlayer m_Player
Определения Hand_Events.c:42
const float ENVIRO_TICK_RATE
Определения 3_Game/constants.c:720

Перекрестные ссылки ApplyWetnessToItem(), GameConstants::ENVIRO_TICK_RATE и m_Player.

Используется в ProcessWetnessByRain(), ProcessWetnessByWaterLevel() и Update().