DayZ
1.24
Loading...
Searching...
No Matches
ActionForceDrink.c
Go to the documentation of this file.
1
class
ActionForceDrinkCB
:
ActionContinuousBaseCB
2
{
3
override
void
CreateActionComponent
()
4
{
5
m_ActionData
.
m_ActionComponent
=
new
CAContinuousQuantityEdible
(
UAQuantityConsumed
.
DRINK
,
UATimeSpent
.
DEFAULT
);
6
}
7
};
8
9
class
ActionForceDrink
: ActionForceConsume
10
{
11
void
ActionForceDrink
()
12
{
13
m_CallbackClass =
ActionForceDrinkCB
;
14
m_CommandUID =
DayZPlayerConstants
.CMD_ACTIONFB_EMPTY_VESSEL;
15
m_FullBody
=
true
;
16
m_StanceMask
=
DayZPlayerConstants
.STANCEMASK_ERECT |
DayZPlayerConstants
.STANCEMASK_CROUCH;
17
m_Text
=
"#give_drink"
;
18
}
19
20
override
void
CreateConditionComponents
()
21
{
22
m_ConditionTarget
=
new
CCTMan
(
UAMaxDistances
.
DEFAULT
);
23
m_ConditionItem
=
new
CCINonRuined
;
24
}
25
26
override
bool
ActionCondition
(
PlayerBase
player
, ActionTarget
target
,
ItemBase
item
)
27
{
28
if
(!
super
.ActionCondition(
player
,
target
,
item
))
29
return
false
;
30
31
PlayerBase
target_player
=
PlayerBase
.Cast(
target
.GetObject());
32
33
if
(
target_player
)
34
return
target_player
.CanEatAndDrink();
35
else
36
return
false
;
37
}
38
39
};
40
m_FullBody
bool m_FullBody
Definition
ActionBase.c:52
m_Text
string m_Text
Definition
ActionBase.c:49
m_ConditionItem
ref CCIBase m_ConditionItem
Definition
ActionBase.c:55
m_ConditionTarget
ref CCTBase m_ConditionTarget
Definition
ActionBase.c:56
m_StanceMask
int m_StanceMask
Definition
ActionBase.c:53
ActionBaseCB::m_ActionData
ActionData m_ActionData
Definition
AnimatedActionBase.c:3
ActionContinuousBaseCB
Definition
ActionContinuousBase.c:2
ActionData::m_ActionComponent
ref CABase m_ActionComponent
Definition
ActionBase.c:30
ActionForceDrinkCB
Definition
ActionForceDrink.c:2
ActionForceDrinkCB::CreateActionComponent
override void CreateActionComponent()
Definition
ActionForceDrink.c:3
ActionForceDrink
Definition
ActionForceDrink.c:10
ActionForceDrink::ActionForceDrink
void ActionForceDrink()
Definition
ActionForceDrink.c:11
ActionForceDrink::ActionCondition
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
Definition
ActionForceDrink.c:26
ActionForceDrink::CreateConditionComponents
override void CreateConditionComponents()
Definition
ActionForceDrink.c:20
CAContinuousQuantityEdible
Definition
CAContinuousQuantityEdible.c:2
CCINonRuined
Definition
CCINonRuined.c:2
CCTMan
Definition
CCTMan.c:2
ItemBase
Definition
InventoryItem.c:697
Param3
Definition
EntityAI.c:95
PlayerBase
Definition
PlayerBaseClient.c:2
UAMaxDistances
Definition
ActionConstants.c:105
UAMaxDistances::DEFAULT
const float DEFAULT
Definition
ActionConstants.c:107
UAQuantityConsumed
Definition
ActionConstants.c:4
UAQuantityConsumed::DRINK
const float DRINK
Definition
ActionConstants.c:13
UATimeSpent
Definition
ActionConstants.c:27
UATimeSpent::DEFAULT
const float DEFAULT
Definition
ActionConstants.c:28
DayZPlayerConstants
DayZPlayerConstants
defined in C++
Definition
dayzplayer.c:597
scripts
4_World
Classes
UserActionsComponent
Actions
Continuous
ActionForceDrink.c
Generated by
1.10.0