DayZ 1.24
Loading...
Searching...
No Matches
TelescopicBaton.c
Go to the documentation of this file.
2{
3 protected int m_MeleeMode;
4 protected int m_MeleeHeavyMode;
5 protected int m_MeleeSprintMode;
6
8
10 {
12 m_MeleeMode = 0;
15
16 m_Openable = new OpenableBehaviour(false);
17
18 RegisterNetSyncVariableBool("m_Openable.m_IsOpened");
19
21 }
22
23 override void Open()
24 {
25 m_Openable.Open();
26 SetSynchDirty();
27
29 m_MeleeMode = 3;
32
34 }
35
36 override void Close()
37 {
38 m_Openable.Close();
39 SetSynchDirty();
40
42 m_MeleeMode = 0;
45
47 }
48
49 override bool IsOpen()
50 {
51 return m_Openable.IsOpened();
52 }
53
54 protected void UpdateVisualState()
55 {
56 if (IsOpen())
57 SetAnimationPhase("Doors1", 0.0);
58 else
59 SetAnimationPhase("Doors1", 1.0);
60 }
61
62 override int GetMeleeMode()
63 {
64 return m_MeleeMode;
65 }
66
67 override int GetMeleeHeavyMode()
68 {
69 return m_MeleeHeavyMode;
70 }
71
72 override int GetMeleeSprintMode()
73 {
74 return m_MeleeSprintMode;
75 }
76
78 {
79 super.OnVariablesSynchronized();
80
82 }
83
84 override void SetActions()
85 {
86 super.SetActions();
89 }
90}
void AddAction(typename actionName)
override void Close()
override void OnVariablesSynchronized()
override void SetActions()
ref OpenableBehaviour m_Openable
override int GetMeleeMode()
override bool IsOpen()
override int GetMeleeHeavyMode()
override int GetMeleeSprintMode()
override void Open()