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

◆ InitGridHeight()

void Container::InitGridHeight ( )
inlineprotected

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

320 {
321 m_Rows.Clear();
322 m_ShowedItemPositions.Clear();
323
324 ref CargoContainerRow row;
325
326 #ifdef PLATFORM_CONSOLE
327 int cargo_height = 1;
328 #else
329 int cargo_height = m_Entity.GetInventory().GetCargoFromIndex(m_CargoIndex).GetHeight();
330 #endif
331
332 for ( int j = 0; j < cargo_height; j++ )
333 {
334 row = new CargoContainerRow( this );
335
336 row.SetNumber( j );
337 row.SetEntity( m_Entity );
338
339 #ifdef PLATFORM_WINDOWS
340 #ifndef PLATFORM_CONSOLE
341 row.SetWidth( m_Entity.GetInventory().GetCargoFromIndex(m_CargoIndex).GetWidth(), false );
342 #endif
343 #endif
344
345 row.GetRootWidget().SetSort( j, false );
346 m_Rows.Insert( row );
347 }
348
349 float y;
350 row.GetRootWidget().FindAnyWidget( "Icon0" ).GetScreenSize( y, m_IconSize );
351 #ifdef PLATFORM_WINDOWS
352 #ifndef PLATFORM_CONSOLE
353 row.GetRootWidget().FindAnyWidget( "Spacer0" ).GetScreenSize( m_SpaceSize, y );
354 #endif
355 #endif
356
357 m_Resizer2.ResizeParentToChild();
358#ifndef PLATFORM_CONSOLE
359 m_Resizer1.ResizeParentToChild();
360#endif
361 }
EntityAI m_Entity
Определения ActionDebug.c:11
Icon y
ref SizeToChild m_Resizer2
Определения CargoContainer.c:27
ref SizeToChild m_Resizer1
Определения CargoContainer.c:25
int m_CargoIndex
Определения CargoContainer.c:7
float m_SpaceSize
Определения CargoContainer.c:16
float m_IconSize
Определения CargoContainer.c:15
ref map< EntityAI, ref Param3< ref Icon, int, int > > m_ShowedItemPositions
Определения CargoContainer.c:12
ref array< ref CargoContainerRow > m_Rows
Определения CargoContainer.c:10

Перекрестные ссылки m_CargoIndex, m_Entity, m_IconSize, m_Resizer1, m_Resizer2, m_Rows, m_ShowedItemPositions, m_SpaceSize и y.

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