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

◆ GetItemOnSlot()

ItemBase ManBase::GetItemOnSlot ( string slot_type)
inlineprotected

Returns item that's on this player's attachment slot. Parameter slot_type should be a string from config parameter 'itemInfo[]' like "Legs", "Headgear" and so on.

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

981 {
982 int slot_id = InventorySlots.GetSlotIdFromString(slot_type);
983 EntityAI item_EAI = this.GetInventory().FindAttachment(slot_id);
984 ItemBase item_IB = ItemBase.Cast(item_EAI);
985
986 if (item_EAI && !item_IB)
987 {
988 string str = "Warning! GetItemOnSlot() >> found item on slot " + slot_type + " can't be cast to ItemBase! Found item is " + item_EAI.GetType() + " and the player is " + GetType() + "!";
989 Error(str);
990 return null;
991 }
992
993 return item_IB;
994 }
class LogManager EntityAI
eBleedingSourceType GetType()
class GP5GasMask extends MaskBase ItemBase
void Error(string err)
Messagebox with error message.
Определения EnDebug.c:90

Перекрестные ссылки Error(), InventorySlots::GetSlotIdFromString() и GetType().

Используется в BrokenLegForceProne(), GetItemOnHead() и IsWearingSplint().