72 {
73 bool success = true;
74
75 InventoryLocation il = new InventoryLocation();
76
78 if (
EntityAI.CastTo(targetEntity, action_data.m_Target.GetObject()))
79 {
80 ArrowManagerBase arrowManager = targetEntity.GetArrowManager();
81 if (arrowManager)
82 {
84 if (targetArrow)
85 {
86 il.
SetHands(action_data.m_Player,targetArrow);
87 if (action_data.m_Player.GetInventory().HasInventoryReservation(targetArrow, il))
88 {
89 success = false;
90 }
91 else
92 {
93 action_data.m_Player.GetInventory().AddInventoryReservationEx(targetArrow, il, GameInventory.c_InventoryReservationTimeoutMS);
94 }
95 }
96 }
97 }
98
99 if (success)
100 {
101 if (il)
102 action_data.m_ReservedInventoryLocations.Insert(il);
103 }
104
105 return success;
106 }
class GP5GasMask extends MaskBase ItemBase
proto native void SetHands(notnull EntityAI parent, EntityAI e)
sets current inventory location type to Hands