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

◆ HasItemQuantity()

static int QuantityConversions::HasItemQuantity ( notnull EntityAI item)
inlinestaticprivate

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

144 {
145 ItemBase ib;
146 if ( Class.CastTo(ib, item) )
147 {
148 if ( item.IsMagazine() )
149 return QUANTITY_COUNT;
150
151 if ( !ib.m_CanShowQuantity )
152 return QUANTITY_HIDDEN;
153
154 int max = item.GetQuantityMax();
155 if ( max > 0 )
156 {
157 if ( ib.m_HasQuantityBar )
158 {
159 return QUANTITY_PROGRESS;
160 }
161 else
162 {
163 if (max == 1)
164 {
165 return QUANTITY_HIDDEN;
166 }
167 else
168 {
169 return QUANTITY_COUNT;
170 }
171 }
172 }
173 }
174 return QUANTITY_HIDDEN;
175 }
class GP5GasMask extends MaskBase ItemBase
const int QUANTITY_PROGRESS
Определения constants.c:516
const int QUANTITY_COUNT
Определения constants.c:515
const int QUANTITY_HIDDEN
Определения constants.c:514

Перекрестные ссылки Class::CastTo(), QUANTITY_COUNT, QUANTITY_HIDDEN и QUANTITY_PROGRESS.

Используется в SlotsIcon::CheckHasQuantity(), Icon::CheckHasQuantityEx(), ActionTargetsCursor::GetItemQuantity(), ScriptedWidgetEventHandler::GetItemQuantity(), InventoryGridController::HasItemQuantity(), Attachments::IsItemActive(), HandsContainer::IsItemActive(), Attachments::IsItemWithQuantityActive(), Container::IsItemWithQuantityActive(), HandsContainer::IsItemWithQuantityActive(), PlayerContainer::IsItemWithQuantityActive(), VicinitySlotsContainer::IsItemWithQuantityActive(), ZombieContainer::IsItemWithQuantityActive(), Icon::SetQuantity(), SlotsIcon::SetQuantity() и UIScriptedMenu::UpdateQuickbarItemCard().