См. определение в файле ItemOptics.c строка 345
346 {
348
350 if (isUsing2D)
351 {
352 path =
"cfgVehicles " +
GetType() +
" OpticsModelInfo";
353 }
354 else
355 {
357 }
358 string temp;
359
361 {
362 if (isUsing2D)
364 else
366
367 if (
g_Game.ConfigIsExisting(
path +
" opticSightTexture"))
368 {
369 g_Game.ConfigGetText(
path +
" opticSightTexture", temp);
371 temp = "";
372 }
373 if (
g_Game.ConfigIsExisting(
path +
" opticSightMaterial"))
374 {
375 g_Game.ConfigGetText(
path +
" opticSightMaterial", temp);
377 temp = "";
378 }
379 }
381 }
eBleedingSourceType GetType()
bool IsUsingOptics2DModel()
Returns whether this ItemOptics uses the 2D optics model.
string m_optic_sight_material
ItemOpticsType GetItemOpticsType()
Returns the ItemOpticsType of this ItemOptics instance.
string m_optic_sight_texture
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().