DayZ 1.24
Loading...
Searching...
No Matches
ActionCheckPulseTarget Class Reference
Inheritance diagram for ActionCheckPulseTarget:
[legend]
Collaboration diagram for ActionCheckPulseTarget:
[legend]

Private Member Functions

void ActionCheckPulseTarget ()
 
override bool ActionCondition (PlayerBase player, ActionTarget target, ItemBase item)
 
override GetInputType ()
 
override void CreateConditionComponents ()
 
override void OnFinishProgressServer (ActionData action_data)
 
override void OnFinishProgressClient (ActionData action_data)
 
- Private Member Functions inherited from ActionContinuousBase
void OnStartAnimationLoopServer (ActionData action_data)
 
void OnStartAnimationLoopClient (ActionData action_data)
 
void OnEndAnimationLoopServer (ActionData action_data)
 
void OnEndAnimationLoopClient (ActionData action_data)
 
void OnFinishProgressServer (ActionData action_data)
 
void OnFinishProgressClient (ActionData action_data)
 

Static Private Member Functions

static string GetPulseMessage (EPulseType pulse_type, int blood_level)
 

Private Attributes

const int TARGET_IRREGULAR_PULSE_BIT = 1 << 31
 

Detailed Description

Definition at line 9 of file ActionCheckPulseTarget.c.

Constructor & Destructor Documentation

◆ ActionCheckPulseTarget()

void ActionCheckPulseTarget::ActionCheckPulseTarget ( )
inlineprivate

Member Function Documentation

◆ ActionCondition()

override bool ActionCheckPulseTarget::ActionCondition ( PlayerBase player,
ActionTarget target,
ItemBase item )
inlineprivate

Definition at line 57 of file ActionCheckPulseTarget.c.

58 {
59 PlayerBase ntarget = PlayerBase.Cast(target.GetObject());
60 if (ntarget && ntarget.IsAlive())
61 return true;
62 return false;
63 }

◆ CreateConditionComponents()

override void ActionCheckPulseTarget::CreateConditionComponents ( )
inlineprivate

Definition at line 69 of file ActionCheckPulseTarget.c.

70 {
73 }
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56
Definition CCTMan.c:2
const float DEFAULT

References UAMaxDistances::DEFAULT, m_ConditionItem, and m_ConditionTarget.

◆ GetInputType()

override ActionCheckPulseTarget::GetInputType ( )
inlineprivate

◆ GetPulseMessage()

static string ActionCheckPulseTarget::GetPulseMessage ( EPulseType pulse_type,
int blood_level )
inlinestaticprivate

Definition at line 23 of file ActionCheckPulseTarget.c.

24 {
25 //builds string table keys:
26
27 //pulse_strong
28 //pulse_decent
29 //pulse_moderate
30 //pulse_weak
31 //pulse_faint
32 //pulse_strong_irregular
33 //pulse_decent_irregular
34 //pulse_moderate_irregular
35 //pulse_weak_irregular
36 //pulse_faint_irregular
37
38 string blood_msg = "strong";
39 string pulse_msg = "";
40
41 if (pulse_type == EPulseType.IRREGULAR)
42 pulse_msg = "_irregular";
43 if (blood_level == EStatLevels.HIGH)
44 blood_msg = "decent";
45 if (blood_level == EStatLevels.MEDIUM)
46 blood_msg = "moderate";
47 if (blood_level == EStatLevels.LOW)
48 blood_msg = "weak";
49 if (blood_level == EStatLevels.CRITICAL)
50 blood_msg = "faint";
51 //string message = blood_msg + " " + pulse_msg + " pulse";
52 string message = "#" + "pulse_" + blood_msg + pulse_msg;
53 return message;
54
55 }
EPulseType
Definition EPulseType.c:2
EStatLevels
Definition EStatLevels.c:2

◆ OnFinishProgressClient()

override void ActionCheckPulseTarget::OnFinishProgressClient ( ActionData action_data)
inlineprivate

Definition at line 90 of file ActionCheckPulseTarget.c.

91 {
92 PlayerBase ntarget = PlayerBase.Cast(action_data.m_Target.GetObject());
93
94 if (ntarget)
95 action_data.m_Player.m_CheckPulseLastTarget = ntarget;
96 }

◆ OnFinishProgressServer()

override void ActionCheckPulseTarget::OnFinishProgressServer ( ActionData action_data)
inlineprivate

Definition at line 75 of file ActionCheckPulseTarget.c.

76 {
77 PlayerBase target_player = PlayerBase.Cast(action_data.m_Target.GetObject());
78 if (target_player)
79 {
80 PlayerBase player = action_data.m_Player;
81 CachedObjectsParams.PARAM1_INT.param1 = target_player.GetStatLevelBlood();
82 bool pulse_type = target_player.GetPulseType();
83 if (pulse_type == EPulseType.IRREGULAR)
85
86 GetGame().RPCSingleParam(player, ERPCs.RPC_CHECK_PULSE, CachedObjectsParams.PARAM1_INT, true, player.GetIdentity());
87 }
88 }
ERPCs
Definition ERPCs.c:2
static ref Param1< int > PARAM1_INT
proto native CGame GetGame()

References GetGame(), CachedObjectsParams::PARAM1_INT, and TARGET_IRREGULAR_PULSE_BIT.

Member Data Documentation

◆ TARGET_IRREGULAR_PULSE_BIT

const int ActionCheckPulseTarget::TARGET_IRREGULAR_PULSE_BIT = 1 << 31
private

Definition at line 11 of file ActionCheckPulseTarget.c.

Referenced by OnFinishProgressServer().


The documentation for this class was generated from the following file: