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

◆ InitReddotData()

void ItemOptics::InitReddotData ( )
inlineprotected

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

375 {
376 bool isUsing2D = IsUsingOptics2DModel();
377
378 string path;
379 if (isUsing2D)
380 {
381 path = "cfgVehicles " + GetType() + " OpticsModelInfo";
382 }
383 else
384 {
385 path = "cfgVehicles " + GetType() + " OpticsInfo";
386 }
387 string temp;
388
389 if (g_Game.ConfigIsExisting(path))
390 {
391 if (isUsing2D)
393 else
394 m_reddot_index = GetHiddenSelectionIndex("reddot");
395
396 if (g_Game.ConfigIsExisting(path + " opticSightTexture"))
397 {
398 g_Game.ConfigGetText(path + " opticSightTexture", temp);
400 temp = "";
401 }
402 if (g_Game.ConfigIsExisting(path + " opticSightMaterial"))
403 {
404 g_Game.ConfigGetText(path + " opticSightMaterial", temp);
406 temp = "";
407 }
408 }
409 m_data_set = true;
410 }
eBleedingSourceType GetType()
DayZGame g_Game
Определения DayZGame.c:4074
string path
Определения OptionSelectorMultistate.c:142
int m_reddot_index
Определения ItemOptics.c:9
bool IsUsingOptics2DModel()
Returns whether this ItemOptics uses the 2D optics model.
Определения ItemOptics.c:207
bool m_data_set
Определения ItemOptics.c:3
string m_optic_sight_material
Определения ItemOptics.c:13
ItemOpticsType GetItemOpticsType()
Returns the ItemOpticsType of this ItemOptics instance.
Определения ItemOptics.c:201
string m_optic_sight_texture
Определения ItemOptics.c:12
proto native int FindOptics2DSelection(string selectionName, bool ignoreCase=true)
Finds selection index by name.

Перекрестные ссылки ItemOpticsType::FindOptics2DSelection(), g_Game, GetItemOpticsType(), GetType(), IsUsingOptics2DModel(), m_data_set, m_optic_sight_material, m_optic_sight_texture, m_reddot_index и path.

Используется в ItemOptics() и ShowReddot().