DayZ Scripts
v1.21.156300 ยท Jun 20, 2023
 
Loading...
Searching...
No Matches
ActionDrink.c
Go to the documentation of this file.
2{
3 override void CreateActionComponent()
4 {
6 }
7};
8
10{
12 {
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_DRINK;
15 m_CommandUIDProne = DayZPlayerConstants.CMD_ACTIONFB_DRINK;
16 m_Text = "#drink";
17 }
18
20 {
23 }
24
25 override bool IsDrink()
26 {
27 return true;
28 }
29
30 override bool HasTarget()
31 {
32 return false;
33 }
34
35 override bool ActionCondition( PlayerBase player, ActionTarget target, ItemBase item )
36 {
37 if (!super.ActionCondition(player, target, item))
38 return false;
39
40 return player.CanEatAndDrink();
41 }
42};
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56
protected string m_Text
Definition ActionBase.c:49
class ActionTargets ActionTarget
protected ActionData m_ActionData
ref CABase m_ActionComponent
Definition ActionBase.c:30
override void CreateActionComponent()
Definition ActionDrink.c:3
override bool IsDrink()
Definition ActionDrink.c:25
override void CreateConditionComponents()
Definition ActionDrink.c:19
void ActionDrink()
Definition ActionDrink.c:11
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
Definition ActionDrink.c:35
override bool HasTarget()
Definition ActionDrink.c:30
protected int m_CommandUIDProne
const float DEFAULT
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602