Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_DestructionBaseData.c
Go to the documentation of this file.
2{
3 // This integer is public as we don't want to have unnecessary getter & setter calls for it
4 int m_iNextFreeIndex = -1;
5 protected float m_fPreviousHealth;
6 protected ref SCR_DestructionHitInfo m_HitInfo;
7 protected ref ScriptInvoker m_OnDamage;
8 protected bool m_bDestructionQueued = false;
9
10 //------------------------------------------------------------------------------------------------
11 void Reset()
12 {
15 delete m_HitInfo;
16 delete m_OnDamage;
17 }
18
19 //------------------------------------------------------------------------------------------------
20 void SetDestructionQueued(bool destructionQueued)
21 {
22 m_bDestructionQueued = destructionQueued;
23 }
24
25 //------------------------------------------------------------------------------------------------
27 {
29 }
30
31 //------------------------------------------------------------------------------------------------
33 {
34 return m_fPreviousHealth;
35 }
36
37 //------------------------------------------------------------------------------------------------
38 void SetPreviousHealth(float previousHealth)
39 {
40 m_fPreviousHealth = previousHealth;
41 }
42
43 //------------------------------------------------------------------------------------------------
45 {
46 SCR_DestructionHitInfo hitinfo = m_HitInfo;
47 m_HitInfo = null;
48 }
49
50 //------------------------------------------------------------------------------------------------
51 SCR_DestructionHitInfo GetHitInfo(bool createNew = true)
52 {
53 if (!m_HitInfo && createNew)
54 m_HitInfo = new SCR_DestructionHitInfo();
55 return m_HitInfo;
56 }
57
58 //------------------------------------------------------------------------------------------------
59 ScriptInvoker GetOnDamage(bool createNew = true)
60 {
61 if (!m_OnDamage && createNew)
63 return m_OnDamage;
64 }
65}
void SetDestructionQueued(bool destructionQueued)
ScriptInvoker GetOnDamage(bool createNew=true)
SCR_DestructionHitInfo GetHitInfo(bool createNew=true)
void SetPreviousHealth(float previousHealth)
ref SCR_DestructionHitInfo m_HitInfo
ScriptInvokerBase< func > ScriptInvoker
Definition tools.c:134