Dayz Explorer 1.28.160049
Loading...
Searching...
No Matches
actiondecraftropebelt.c
Go to the documentation of this file.
2{
3 override void CreateActionComponent()
4 {
5 m_ActionData.m_ActionComponent = new CAContinuousTime(UATimeSpent.DEFAULT_DECRAFT);
6 }
7
9 private const float TIME_TO_CRAFT_CLOTHES = 5.0;
10}
11
13{
15 {
16 m_CallbackClass = ActionDeCraftRopeBeltCB;
17 m_CommandUID = DayZPlayerConstants.CMD_ACTIONFB_CRAFTING;
18 m_FullBody = true;
19 m_StanceMask = DayZPlayerConstants.STANCEMASK_CROUCH | DayZPlayerConstants.STANCEMASK_ERECT;
20 m_SpecialtyWeight = UASoftSkillsWeight.ROUGH_HIGH;
21
22 m_Text = "#STR_DeCraftRopeBelt";
23 }
24
26 {
27 m_ConditionItem = new CCINonRuined();
28 m_ConditionTarget = new CCTNone();
29 }
30
31 override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
32 {
33 return item.GetInventory().AttachmentCount() == 0;
34 }
35
36 override bool HasTarget()
37 {
38 return false;
39 }
40
41 override void OnFinishProgressServer(ActionData action_data)
42 {
43 EntityAI ropebelt = action_data.m_MainItem;
44 EntityAI rope = action_data.m_Player.SpawnEntityOnGroundRaycastDispersed("Rope");
45 action_data.m_MainItem.Delete();
46
47 MiscGameplayFunctions.TransferItemProperties(ropebelt, rope);
48 }
49}
int m_CommandUID
Definition actionbase.c:31
int m_StanceMask
Definition actionbase.c:33
ActionDeCraftRopeBeltCB ActionContinuousBaseCB ActionDeCraftRopeBelt()
ActionData m_ActionData
bool HasTarget()
Definition actionbase.c:244
void CreateConditionComponents()
Definition actionbase.c:230
void OnFinishProgressServer(ActionData action_data)
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602