DayZ 1.24
Loading...
Searching...
No Matches
ActionWashHandsWaterOne.c
Go to the documentation of this file.
8
9class ActionWashHandsWaterOne extends ActionInteractLoopBase
10{
12 {
13 m_CallbackClass = ActionWashHandsWaterOneCB;
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONFB_WASHHANDSPOND;
15 m_FullBody = true;
16 m_StanceMask = DayZPlayerConstants.STANCEMASK_CROUCH;
17 m_Text = "#wash_hands";
18 }
19
25
26 override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
27 {
28 // Other conditions are in CCTWaterSurface
29 return (GetGame().IsMultiplayer() && GetGame().IsServer()) || (player.HasBloodyHands() && !player.GetItemInHands() && !player.GetItemOnSlot("Gloves"));
30 }
31
33 {
34 if (action_data.m_State == UA_FINISHED)
35 {
37 module_lifespan.UpdateBloodyHandsVisibility(action_data.m_Player, false);
38 }
39 }
40};
bool m_FullBody
Definition ActionBase.c:52
string m_Text
Definition ActionBase.c:49
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56
int m_StanceMask
Definition ActionBase.c:53
void PluginLifespan()
PluginBase GetPlugin(typename plugin_type)
ActionData m_ActionData
ref CABase m_ActionComponent
Definition ActionBase.c:30
override void CreateConditionComponents()
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void OnEndServer(ActionData action_data)
const float DEFAULT
const float WASH_HANDS
const string ALL
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:597
proto native CGame GetGame()
const int UA_FINISHED
Definition constants.c:436