DayZ
1.24
Loading...
Searching...
No Matches
StateCB.c
Go to the documentation of this file.
1
class
SymptomCB
extends
HumanCommandActionCallback
2
{
3
//int m_SymptomUID;
4
float
m_RunTime
;
5
float
m_StartingTime
;
6
PlayerBase
m_Player
;
7
8
override
void
OnFinish
(
bool
pCanceled
)
9
{
10
if
(
m_Player
&&
m_Player
.GetSymptomManager())
11
m_Player
.GetSymptomManager().OnAnimationFinished();
12
}
13
14
15
void
Init
(
float
run_time
,
PlayerBase
player
)
16
{
17
EnableCancelCondition
(
true
);
18
m_RunTime
=
run_time
* 1000;
19
m_StartingTime =
GetGame
().GetTime();
20
m_Player
=
player
;
21
22
if
(
m_Player
&&
m_Player
.GetSymptomManager())
23
m_Player
.GetSymptomManager().OnAnimationStarted();
24
}
25
26
bool
CancelCondition
()
27
{
28
if
(
m_RunTime
> 0 && (
GetGame
().
GetTime
() > m_StartingTime +
m_RunTime
))
29
return
true
;
30
else
31
return
false
;
32
}
33
34
override
bool
IsSymptomCallback
()
35
{
36
return
true
;
37
}
38
39
};
m_Player
DayZPlayer m_Player
Definition
Hand_Events.c:42
GetTime
float GetTime()
Definition
NotificationSystem.c:35
HumanCommandActionCallback
Definition
StateCB.c:2
HumanCommandActionCallback::m_StartingTime
float m_StartingTime
Definition
StateCB.c:5
HumanCommandActionCallback::m_RunTime
float m_RunTime
Definition
StateCB.c:4
HumanCommandActionCallback::CancelCondition
bool CancelCondition()
Definition
StateCB.c:26
HumanCommandActionCallback::Init
void Init(float run_time, PlayerBase player)
Definition
StateCB.c:15
HumanCommandActionCallback::OnFinish
override void OnFinish(bool pCanceled)
Definition
StateCB.c:8
HumanCommandActionCallback::IsSymptomCallback
override bool IsSymptomCallback()
Definition
StateCB.c:34
HumanCommandActionCallback::m_Player
PlayerBase m_Player
Definition
StateCB.c:6
Param3
Definition
EntityAI.c:95
PlayerBase
Definition
PlayerBaseClient.c:2
GetGame
proto native CGame GetGame()
m_RunTime
float m_RunTime
Definition
tools.c:214
EnableCancelCondition
proto native void EnableCancelCondition(bool pEnable)
scripts
4_World
Classes
PlayerSymptoms
StateCB.c
Generated by
1.10.0