34 HescoBox hesco = HescoBox.Cast(target.GetObject());
36 if( hesco.GetState() == HescoBox.UNFOLDED )
48 if ( player.IsPlacingLocal() )
54 if ( hesco.CanBeFilledAtPosition( player.GetPosition() ) )
56 if ( hesco.GetState() == HescoBox.UNFOLDED )
61 else if( hesco.GetState() == HescoBox.FILLED)
76 if (
Class.
CastTo(hesco,action_data.m_Target.GetObject()) )
78 const float ITEM_DAMAGE = 5;
79 action_data.m_MainItem.DecreaseHealth(
"",
"", ITEM_DAMAGE);
81 if (hesco.GetState() == HescoBox.UNFOLDED)
85 else if (hesco.GetState() == HescoBox.FILLED)
96 if (
Class.
CastTo(hesco,action_data.m_Target.GetObject()) )
98 if ( hesco.GetState() == HescoBox.UNFOLDED )
102 else if ( hesco.GetState() == HescoBox.FILLED )
class ActionTargets ActionTarget
ref CCIBase m_ConditionItem
ref CCTBase m_ConditionTarget
void ActionContinuousBase()
override void OnFinishProgressServer(ActionData action_data)
override void OnActionInfoUpdate(PlayerBase player, ActionTarget target, ItemBase item)
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void CreateConditionComponents()
override void OnFinishProgressClient(ActionData action_data)
override void CreateActionComponent()
Super root of all classes in Enforce script.
DayZPlayerConstants
defined in C++
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.