DayZ 1.24
Loading...
Searching...
No Matches
ActionZoomIn.c
Go to the documentation of this file.
2{
4 {
5 m_Text = "#zoom_in";
6 }
7
13
14 override bool HasTarget()
15 {
16 return false;
17 }
18
19 override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
20 {
22 if (Class.CastTo(optic, item) && !optic.IsInOptics())
23 return true;
24 return false;
25 }
26
28 {
30 if (Class.CastTo(optic, action_data.m_MainItem))
31 optic.EnterOptics();
32 }
33};
string m_Text
Definition ActionBase.c:49
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56
override void OnEndServer(ActionData action_data)
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void CreateConditionComponents()
Definition ActionZoomIn.c:8
override bool HasTarget()
void ActionZoomIn()
Definition ActionZoomIn.c:3
Super root of all classes in Enforce script.
Definition EnScript.c:11
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.