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

◆ InitDOFAvailability()

bool ItemOptics::InitDOFAvailability ( )
inlineprotected

optics with more than 1x zoom do not allow DOF changes

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

426 {
427 float fov_max;
428 string path = "cfgVehicles " + GetType() + " OpticsInfo";
429
430 /*
431 Weapon_Base weapon = Weapon_Base.Cast(GetHierarchyParent());
432 if (!weapon)
433 return false; // no DOF for handheld optics
434 */
435 fov_max = GetGame().ConfigGetFloat(path + " opticsZoomMax");
436 if (fov_max >= GameConstants.DZPLAYER_CAMERA_FOV_IRONSIGHTS)
437 {
438 return true;
439 }
440 return false;
441 }
eBleedingSourceType GetType()
string path
Определения OptionSelectorMultistate.c:142
proto native float ConfigGetFloat(string path)
Get float value from config on path.
proto native CGame GetGame()

Перекрестные ссылки CGame::ConfigGetFloat(), GameConstants::DZPLAYER_CAMERA_FOV_IRONSIGHTS, GetGame(), GetType() и path.

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