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

Private Member Functions

void ActionUncoverHeadTarget ()
 
override void CreateConditionComponents ()
 
override GetInputType ()
 
override bool ActionCondition (PlayerBase player, ActionTarget target, ItemBase item)
 
override void OnFinishProgressServer (ActionData action_data)
 
bool IsWearingBurlap (PlayerBase player)
 

Detailed Description

Definition at line 9 of file ActionUncoverHeadTarget.c.

Constructor & Destructor Documentation

◆ ActionUncoverHeadTarget()

void ActionUncoverHeadTarget::ActionUncoverHeadTarget ( )
inlineprivate

Definition at line 11 of file ActionUncoverHeadTarget.c.

12 {
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONFB_INTERACT;
15 m_FullBody = true;
16 m_StanceMask = DayZPlayerConstants.STANCEMASK_ERECT | DayZPlayerConstants.STANCEMASK_CROUCH;
17 m_Text = "#uncover_players_head";
18 }
bool m_FullBody
Definition ActionBase.c:52
string m_Text
Definition ActionBase.c:49
int m_StanceMask
Definition ActionBase.c:53
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:597

References AnimatedActionBase::m_CallbackClass, AnimatedActionBase::m_CommandUID, m_FullBody, m_StanceMask, and m_Text.

Member Function Documentation

◆ ActionCondition()

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

Definition at line 31 of file ActionUncoverHeadTarget.c.

32 {
34 if (Class.CastTo(targetPlayer, target.GetObject()))
35 {
37 return true;
38 }
39 return false;
40 }
bool IsWearingBurlap(PlayerBase player)
Super root of all classes in Enforce script.
Definition EnScript.c:11
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.

References Class::CastTo(), and IsWearingBurlap().

◆ CreateConditionComponents()

override void ActionUncoverHeadTarget::CreateConditionComponents ( )
inlineprivate

Definition at line 20 of file ActionUncoverHeadTarget.c.

21 {
24 }
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 ActionUncoverHeadTarget::GetInputType ( )
inlineprivate

◆ IsWearingBurlap()

bool ActionUncoverHeadTarget::IsWearingBurlap ( PlayerBase player)
inlineprivate

Definition at line 49 of file ActionUncoverHeadTarget.c.

50 {
52 Class.CastTo(attachment, player.GetInventory().FindAttachment(InventorySlots.HEADGEAR));
53 if (attachment && attachment.GetType() == "BurlapSackCover")
54 return true;
55 return false;
56 }
provides access to slot configuration

References Class::CastTo().

Referenced by ActionCondition().

◆ OnFinishProgressServer()

override void ActionUncoverHeadTarget::OnFinishProgressServer ( ActionData action_data)
inlineprivate

Definition at line 42 of file ActionUncoverHeadTarget.c.

43 {
44 PlayerBase targetPlayer = PlayerBase.Cast(action_data.m_Target.GetObject());
45 if (CanReceiveAction(action_data.m_Target))
46 UncoverHead(PlayerBase.Cast(action_data.m_Target.GetObject()), action_data.m_Player);
47 }
bool CanReceiveAction(ActionTarget target)
Definition ActionBase.c:594
void UncoverHead(PlayerBase target, PlayerBase source)

References CanReceiveAction(), and ActionUncoverHeadBase::UncoverHead().


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