1322 {
1323 super.EEDelete(parent);
1324 PlayerBase player = PlayerBase.Cast(GetHierarchyRootPlayer());
1325 if (player)
1326 {
1328
1329 if (player.IsAlive())
1330 {
1331 int r_index = player.GetHumanInventory().FindUserReservedLocationIndex(this);
1332 if (r_index >= 0)
1333 {
1334 InventoryLocation r_il = new InventoryLocation;
1335 player.GetHumanInventory().GetUserReservedLocation(r_index,r_il);
1336
1337 player.GetHumanInventory().ClearUserReservedLocationAtIndex(r_index);
1340 {
1341 r_il.
GetParent().GetOnReleaseLock().Invoke(
this);
1342 }
1344 {
1345 r_il.
GetParent().GetOnAttachmentReleaseLock().Invoke(
this, r_il.
GetSlot());
1346 }
1347
1348 }
1349
1350 player.RemoveQuickBarEntityShortcut(this);
1351 }
1352 }
1353 }
InventoryLocationType
types of Inventory Location
void OnInventoryExit(Man player)
Event called on item when it is removed from the player(Man) inventory, passes the old owner as a par...
proto native EntityAI GetParent()
returns parent of current inventory location
proto native int GetSlot()
returns slot id if current type is Attachment
proto native int GetType()
returns type of InventoryLocation