9 m_Text =
"#use_range_finder";
24 player.SetIronsights(
false);
25 player.SetHandheldOpticsInUse(
true);
28 optic.HideSelection(
"hide");
29 if (NVGoggles.Cast(
optic) &&
optic.ConfigIsExisting(
"simpleHiddenSelections"))
30 optic.SetSimpleHiddenSelectionState(0,
false);
32 if (
optic.HasEnergyManager())
40 rf.GetCompEM().SwitchOn();
46 optic.ShowSelection(
"hide");
47 if (NVGoggles.Cast(
optic) &&
optic.ConfigIsExisting(
"simpleHiddenSelections"))
48 optic.SetSimpleHiddenSelectionState(0,
true);
49 player.SetHandheldOpticsInUse(
false);
51 if (
optic.HasEnergyManager())
59 rf.GetCompEM().SwitchOff();
override void EnterOptics(ItemOptics optic, PlayerBase player)
override void OnActionInfoUpdate(PlayerBase player, ActionTarget target, ItemBase item)
bool m_workingRangefinder
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void ExitOptics(ItemOptics optic, PlayerBase player)
Super root of all classes in Enforce script.
proto native CGame GetGame()
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.