DayZ 1.24
Loading...
Searching...
No Matches
ActionEatFruit.c
Go to the documentation of this file.
8
10{
12 {
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_EAT;
15 m_CommandUIDProne = DayZPlayerConstants.CMD_ACTIONFB_EAT;
16 }
17
18 override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
19 {
20 if (!super.ActionCondition(player, target, item))
21 return false;
23
25 {
26 if (food_item.IsFruit())
27 return true;
28 }
29
30 return false;
31 }
32}
ActionData m_ActionData
ref CABase m_ActionComponent
Definition ActionBase.c:30
override void CreateActionComponent()
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
Super root of all classes in Enforce script.
Definition EnScript.c:11
const float EAT_NORMAL
const float DEFAULT
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:597
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.