DayZ 1.24
Loading...
Searching...
No Matches
ActionFoldObject.c
Go to the documentation of this file.
2{
8
9 override typename GetInputType()
10 {
12 }
13
14 override bool HasProgress()
15 {
16 return false;
17 }
18
19 override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
20 {
21 Object targetObject = target.GetObject();
22 if (targetObject.IsInherited(HescoBox))
23 {
24 HescoBox hesco = HescoBox.Cast(targetObject);
25
26 if (hesco.GetState() == HescoBox.UNFOLDED)
27 return true;
28 }
29 return false;
30 }
31
33 {
34 Object targetObject = action_data.m_Target.GetObject();
35 HescoBox hesco = HescoBox.Cast(targetObject);
36 if (hesco.GetState() == HescoBox.UNFOLDED)
37 hesco.Fold();
38
39 action_data.m_Player.GetSoftSkillsManager().AddSpecialty(m_SpecialtyWeight);
40 }
41};
string m_Text
Definition ActionBase.c:49
float m_SpecialtyWeight
Definition ActionBase.c:68
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void OnExecuteServer(ActionData action_data)
override GetInputType()
override bool HasProgress()