188 {
189 if (!
GetGame().IsDedicatedServer() )
190 {
191 InventoryLocation il = new InventoryLocation;
193
194 }
195
196 if (LogManager.IsSyncLogEnable())
syncDebugPrint(
"[inv] " +
GetDebugName(
this) +
" STS = " + GetSimulationTimeStamp() +
" ::Take2Hands(" +
typename.EnumToString(
InventoryMode, mode) +
") item=" +
Object.GetDebugName(item));
198
199 InventoryLocation src_item = new InventoryLocation;
200 if (item.GetInventory().GetCurrentInventoryLocation(src_item))
201 {
202 if (itemInHands == null)
203 {
204 InventoryLocation hand_dst = new InventoryLocation;
207 }
209 GetInventory().SwapEntities(mode, itemInHands, item);
211 }
212 }
void syncDebugPrint(string s)
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
void UpdateInventoryMenu()
proto native HumanInventory GetHumanInventory()
proto native EntityAI GetEntityInHands()
override bool TakeToDst(InventoryMode mode, notnull InventoryLocation src, notnull InventoryLocation dst)
proto native void SetHands(notnull EntityAI parent, EntityAI e)
sets current inventory location type to Hands
override string GetDebugName()
proto native CGame GetGame()