17 if (player.IsPlacingLocal())
23 if (targetIB && targetIB.GetHierarchyRoot() == targetIB && item)
25 if (item.HasEnergyManager() && !item.GetCompEM().IsPlugged() && targetIB.HasEnergyManager() && targetIB.GetCompEM().CanReceivePlugFrom(item))
34 return attachedDevice.GetCompEM().HasFreeSocket();
45 if (targetIB.HasEnergyManager())
49 targetIB = attachedDevice;
51 action_data.m_MainItem.GetCompEM().PlugThisInto(targetIB);
53 if (!
g_Game.IsDedicatedServer())
55 if (!action_data.m_Player.IsPlacingLocal())
57 action_data.m_Player.PlacingStartLocal(action_data.m_MainItem);
63 if (!action_data.m_Player.IsPlacingServer())
65 action_data.m_Player.PlacingStartServer(action_data.m_MainItem);
76 targetIB.GetInventory().TakeEntityAsAttachment(
InventoryMode.LOCAL, action_data.m_MainItem);
81 if (!action_data.m_Player.IsPlacingLocal())
82 action_data.m_Player.PlacingStartLocal(action_data.m_MainItem);
91 ItemBase parentAttachment =
ItemBase.Cast(parent.GetAttachmentByType(MetalWire));
92 if (!parentAttachment)
93 parentAttachment =
ItemBase.Cast(parent.GetAttachmentByType(BarbedWire));
95 return parentAttachment;
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
void ActionTarget(Object object, Object parent, int componentIndex, vector cursorHitPos, float utility, string surfaceName="")
ref CCIBase m_ConditionItem
ref CCTBase m_ConditionTarget
ItemBase GetAttachedDevice(ItemBase parent)
override void OnExecuteServer(ActionData action_data)
override void OnExecuteClient(ActionData action_data)
override void CreateConditionComponents()
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
void Process(ActionData action_data)
void ActionSingleUseBase()
DayZPlayerConstants
defined in C++