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

Private Member Functions

void ActionCoverHeadSelf ()
 
override void CreateConditionComponents ()
 
override bool HasTarget ()
 
override bool ActionCondition (PlayerBase player, ActionTarget target, ItemBase item)
 
override void OnFinishProgressServer (ActionData action_data)
 
bool IsWearingHeadgear (PlayerBase player)
 
- 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)
 

Detailed Description

Definition at line 9 of file ActionCoverHeadSelf.c.

Constructor & Destructor Documentation

◆ ActionCoverHeadSelf()

void ActionCoverHeadSelf::ActionCoverHeadSelf ( )
inlineprivate

Definition at line 11 of file ActionCoverHeadSelf.c.

12 {
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_COVERHEAD_SELF;
15 m_StanceMask = DayZPlayerConstants.STANCEMASK_ERECT | DayZPlayerConstants.STANCEMASK_CROUCH | DayZPlayerConstants.STANCEMASK_PRONE;
16 //m_Animation = "INJECTEPIPENS";
18 m_Text = "#put_on_head";
19 }
string m_Text
Definition ActionBase.c:49
float m_SpecialtyWeight
Definition ActionBase.c:68
int m_StanceMask
Definition ActionBase.c:53
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:597

References AnimatedActionBase::m_CallbackClass, AnimatedActionBase::m_CommandUID, m_SpecialtyWeight, m_StanceMask, m_Text, and UASoftSkillsWeight::ROUGH_LOW.

Member Function Documentation

◆ ActionCondition()

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

Definition at line 32 of file ActionCoverHeadSelf.c.

33 {
35 return false;
36
37 return true;
38 }
bool IsWearingHeadgear(PlayerBase player)

References IsWearingHeadgear().

◆ CreateConditionComponents()

override void ActionCoverHeadSelf::CreateConditionComponents ( )
inlineprivate

Definition at line 21 of file ActionCoverHeadSelf.c.

22 {
25 }
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56

References m_ConditionItem, and m_ConditionTarget.

◆ HasTarget()

override bool ActionCoverHeadSelf::HasTarget ( )
inlineprivate

Definition at line 27 of file ActionCoverHeadSelf.c.

28 {
29 return false;
30 }

◆ IsWearingHeadgear()

bool ActionCoverHeadSelf::IsWearingHeadgear ( PlayerBase player)
inlineprivate

Definition at line 52 of file ActionCoverHeadSelf.c.

53 {
54 if (player.GetInventory().FindAttachment(InventorySlots.HEADGEAR))
55 return true;
56 return false;
57 }
provides access to slot configuration

Referenced by ActionCondition().

◆ OnFinishProgressServer()

override void ActionCoverHeadSelf::OnFinishProgressServer ( ActionData action_data)
inlineprivate

Definition at line 40 of file ActionCoverHeadSelf.c.

41 {
43 if (Class.CastTo(new_item, action_data.m_Player.GetInventory().CreateAttachmentEx("BurlapSackCover", InventorySlots.HEADGEAR)))
44 {
45 MiscGameplayFunctions.TransferItemProperties(action_data.m_MainItem, new_item, true, false, true);
46 action_data.m_MainItem.Delete();
47 action_data.m_Player.GetSoftSkillsManager().AddSpecialty(m_SpecialtyWeight);
48 }
49 }
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 m_SpecialtyWeight.


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