DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс ActionCheckPulse

DEPRECATED. Подробнее...

+ Граф наследования:ActionCheckPulse:

Закрытые члены

void ActionCheckPulse ()
 
override void CreateConditionComponents ()
 
override bool ActionCondition (PlayerBase player, ActionTarget target, ItemBase item)
 
override void OnExecuteServer (ActionData action_data)
 
override void OnExecuteClient (ActionData action_data)
 
override void OnEndServer (ActionData action_data)
 

Закрытые статические члены

static string GetPulseMessage (EPulseType pulse_type, int blood_level)
 

Закрытые данные

const int TARGET_IRREGULAR_PULSE_BIT = 1 << 31
 

Подробное описание

DEPRECATED.

Конструктор(ы)

◆ ActionCheckPulse()

void ActionCheckPulse ( )
inlineprivate
6 {
7 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_INTERACTONCE;
8 m_StanceMask = DayZPlayerConstants.STANCEMASK_ERECT | DayZPlayerConstants.STANCEMASK_CROUCH;
9 m_Text = "#check_pulse_target";
10 }
string m_Text
Definition ActionBase.c:58
int m_StanceMask
Definition ActionBase.c:62
int m_CommandUID
Definition AnimatedActionBase.c:143
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602

Перекрестные ссылки AnimatedActionBase::m_CommandUID, ActionBase::m_StanceMask и ActionBase::m_Text.

Методы

◆ ActionCondition()

override bool ActionCondition ( PlayerBase player,
ActionTarget target,
ItemBase item )
inlineprivate
63 {
64 PlayerBase ntarget = PlayerBase.Cast( target.GetObject() );
65 if( ntarget && ntarget.IsAlive())
66 {
67 return true;
68 }
69 return false;
70 }
Definition EntityAI.c:95
Definition PlayerBaseClient.c:2

◆ CreateConditionComponents()

override void CreateConditionComponents ( )
inlineprivate
13 {
16 }
ref CCIBase m_ConditionItem
Definition ActionBase.c:64
ref CCTBase m_ConditionTarget
Definition ActionBase.c:65
Definition CCINone.c:2
Definition CCTMan.c:2
Definition ActionConstants.c:106
const float DEFAULT
Definition ActionConstants.c:108

Перекрестные ссылки UAMaxDistances::DEFAULT, ActionBase::m_ConditionItem и ActionBase::m_ConditionTarget.

◆ GetPulseMessage()

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

Используется в ManBase::OnRPC().

◆ OnEndServer()

override void OnEndServer ( ActionData action_data)
inlineprivate
99 {
100 super.OnEndServer(action_data);
101
102 /*
103 PlayerBase target_player = PlayerBase.Cast(action_data.m_Target.GetObject());
104 PlayerBase player = action_data.m_Player;
105 CachedObjectsParams.PARAM1_INT.param1 = target_player.GetStatLevelBlood();
106 GetGame().RPCSingleParam( target_player ,ERPCs.RPC_CHECK_PULSE, CachedObjectsParams.PARAM1_INT, true, target_player.GetIdentity() );
107 */
108 }

◆ OnExecuteClient()

override void OnExecuteClient ( ActionData action_data)
inlineprivate
89 {
90 PlayerBase ntarget = PlayerBase.Cast( action_data.m_Target.GetObject() );
91
92 if(ntarget)
93 {
94 action_data.m_Player.m_CheckPulseLastTarget = ntarget;
95 }
96 }

◆ OnExecuteServer()

override void OnExecuteServer ( ActionData action_data)
inlineprivate
73 {
74 PlayerBase target_player = PlayerBase.Cast(action_data.m_Target.GetObject());
75 if (target_player)
76 {
77 PlayerBase player = action_data.m_Player;
78 CachedObjectsParams.PARAM1_INT.param1 = target_player.GetStatLevelBlood();
79 bool pulse_type = target_player.GetPulseType();
80 if (pulse_type == EPulseType.IRREGULAR)
82
83 GetGame().RPCSingleParam( player ,ERPCs.RPC_CHECK_PULSE, CachedObjectsParams.PARAM1_INT, true, player.GetIdentity() );
84 }
85 }
ERPCs
Definition ERPCs.c:2
const int TARGET_IRREGULAR_PULSE_BIT
Definition ActionCheckPulse.c:4
Definition UtilityClasses.c:10
static ref Param1< int > PARAM1_INT
Definition UtilityClasses.c:11
proto native CGame GetGame()

Перекрестные ссылки GetGame(), CachedObjectsParams::PARAM1_INT и TARGET_IRREGULAR_PULSE_BIT.

Поля

◆ TARGET_IRREGULAR_PULSE_BIT

const int TARGET_IRREGULAR_PULSE_BIT = 1 << 31
private

Используется в OnExecuteServer() и ManBase::OnRPC().


Объявления и описания членов класса находятся в файле: