|
override int | GetCount () |
| Returns the number of available elements.
|
|
override int | GetCurrentIndex () |
| Returns currently selected element or -1 if none.
|
|
override void | SetIndex (int index) |
| Set provided element as the current one.
|
|
array< float > | ZoomsToArray () |
| Get array of each zoom based on min-max and steps in between.
|
|
void | InsertFov (float fov) |
| Add new fov based on reticle range and zoom.
|
|
int | GetStepsCount () |
|
void | SetCurrentFov (float fov) |
|
float | GetCurrentZoom () |
|
float | GetBaseZoom () |
|
override float | GetBaseFOV () |
| Returns max field of view provided by this info.
|
|
override bool | IsAdjusting () |
| Returns true when current FOV of the optic does not match the target FOV.
|
|
void | ForceUpdate (IEntity owner, BaseSightsComponent sights, float timeSlice) |
|
ScriptInvoker | GetEventOnZoomChanged () |
|
int | GetCount () |
| Returns the number of available elements.
|
|
int | GetCurrentIndex () |
| Returns currently selected element or -1 if none.
|
|
bool | SetNext (bool allowOverflow=true) |
| Selects next available element.
|
|
bool | SetPrevious (bool allowUnderflow=true) |
| Selects previous available element.
|
|
bool | IsAdjusting () |
| Returns true when current FOV of the optic does not match the target FOV.
|
|
float | GetBaseFOV () |
| Returns true when current FOV of the optic does not match the target FOV.
|
|
proto external float | GetFOV () |
| Returns current field of view provided by this info.
|
|
◆ ForceUpdate()
void SCR_SightsZoomFOVInfo.ForceUpdate |
( |
IEntity |
owner, |
|
|
BaseSightsComponent |
sights, |
|
|
float |
timeSlice |
|
) |
| |
◆ GetBaseFOV()
override float SCR_SightsZoomFOVInfo.GetBaseFOV |
( |
| ) |
|
Returns max field of view provided by this info.
Assumes that first FOV is the largest one. Returns zero if FOVs array is empty.
- Returns
- Returns field of view in degrees.
Implements SCR_BaseVariableSightsFOVInfo.
◆ GetBaseZoom()
float SCR_SightsZoomFOVInfo.GetBaseZoom |
( |
| ) |
|
◆ GetCount()
override int SCR_SightsZoomFOVInfo.GetCount |
( |
| ) |
|
◆ GetCurrentFOV()
override float SCR_SightsZoomFOVInfo.GetCurrentFOV |
( |
| ) |
|
|
protected |
Returns current field of view provided by this info.
- Returns
- Returns field of view in degrees.
Implements ScriptedSightsFOVInfo.
◆ GetCurrentIndex()
override int SCR_SightsZoomFOVInfo.GetCurrentIndex |
( |
| ) |
|
◆ GetCurrentZoom()
float SCR_SightsZoomFOVInfo.GetCurrentZoom |
( |
| ) |
|
◆ GetEventOnZoomChanged()
ScriptInvoker SCR_SightsZoomFOVInfo.GetEventOnZoomChanged |
( |
| ) |
|
◆ GetStepsCount()
int SCR_SightsZoomFOVInfo.GetStepsCount |
( |
| ) |
|
◆ GetZoom()
float SCR_SightsZoomFOVInfo.GetZoom |
( |
int |
i, |
|
|
int |
count |
|
) |
| |
|
protected |
◆ InsertFov()
void SCR_SightsZoomFOVInfo.InsertFov |
( |
float |
fov | ) |
|
Add new fov based on reticle range and zoom.
◆ InvokeOnZoomChanged()
void SCR_SightsZoomFOVInfo.InvokeOnZoomChanged |
( |
float |
zoom, |
|
|
float |
fov |
|
) |
| |
|
protected |
◆ IsAdjusting()
override bool SCR_SightsZoomFOVInfo.IsAdjusting |
( |
| ) |
|
◆ OnInit()
Called on initialization.
- Parameters
-
owner | Parent entity. |
sights | Parent sights component. |
Implements ScriptedSightsFOVInfo.
◆ OnUpdate()
override void SCR_SightsZoomFOVInfo.OnUpdate |
( |
IEntity |
owner, |
|
|
BaseSightsComponent |
sights, |
|
|
float |
timeSlice |
|
) |
| |
|
protected |
Called every frame when active to update current state.
- Parameters
-
owner | Parent weapon entity. |
sights | Parent sights component. |
timeSlice | Delta of time since last update. |
Implements ScriptedSightsFOVInfo.
◆ SetCurrentFov()
void SCR_SightsZoomFOVInfo.SetCurrentFov |
( |
float |
fov | ) |
|
◆ SetIndex()
override void SCR_SightsZoomFOVInfo.SetIndex |
( |
int |
index | ) |
|
◆ ZoomsToArray()
array< float > SCR_SightsZoomFOVInfo.ZoomsToArray |
( |
| ) |
|
Get array of each zoom based on min-max and steps in between.
◆ event_OnZoomChanged
ref ScriptInvoker<float, float> SCR_SightsZoomFOVInfo.event_OnZoomChanged |
|
protected |
◆ m_aFOVs
ref array<float> SCR_SightsZoomFOVInfo.m_aFOVs = new array<float> |
|
protected |
◆ m_fBaseZoom
float SCR_SightsZoomFOVInfo.m_fBaseZoom |
|
protected |
◆ m_fCurrentFOV
float SCR_SightsZoomFOVInfo.m_fCurrentFOV |
|
protected |
Immediate field of view value.
◆ m_fInterpolationSpeed
float SCR_SightsZoomFOVInfo.m_fInterpolationSpeed |
|
protected |
◆ m_fStepZoomSize
float SCR_SightsZoomFOVInfo.m_fStepZoomSize |
|
protected |
◆ m_fZoomMax
float SCR_SightsZoomFOVInfo.m_fZoomMax |
|
protected |
◆ m_iCurrentIndex
int SCR_SightsZoomFOVInfo.m_iCurrentIndex = 0 |
|
protected |
Currently selected FOV or 0 (as base fov) if none.
◆ m_iStepsCount
int SCR_SightsZoomFOVInfo.m_iStepsCount = 1 |
|
protected |
The documentation for this interface was generated from the following file:
- Game/Weapon/Sights/SightsFOVInfo/SCR_SightsZoomFOVInfo.c