DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ TakeToDst()

bool GameInventory::TakeToDst ( InventoryMode mode,
notnull InventoryLocation src,
notnull InventoryLocation dst )
inlineprotected

move src to dst

Аргументы
[in]modeinventory mode
[in]srcsource location of the item
[in]dstdestination location of the item

См. определение в файле Inventory.c строка 1055

1056 {
1057 bool ret;
1058 switch (mode)
1059 {
1060 case InventoryMode.SERVER:
1061 ret = LocationSyncMoveEntity(src, dst);
1062 if (ret && dst.IsValid())
1063 InventoryInputUserData.SendServerMove(null, InventoryCommandType.SYNC_MOVE, src, dst);
1064 return ret;
1065 case InventoryMode.LOCAL:
1066 ret = LocationSyncMoveEntity(src, dst);
1067 return ret;
1068 default:
1069 return false;
1070 }
1071 return false;
1072 }
InventoryCommandType
Определения Inventory.c:3
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
Определения Inventory.c:22
static proto native bool LocationSyncMoveEntity(notnull InventoryLocation src_loc, notnull InventoryLocation dst_loc)
synchronously removes item from current inventory location and adds it to destination no anims involv...

Перекрестные ссылки LocationSyncMoveEntity() и InventoryInputUserData::SendServerMove().

Используется в DropEntity(), DropEntityInBounds(), DropEntityWithTransform(), TakeEntityAsTargetAttachmentEx(), TakeEntityToCargoEx(), TakeEntityToInventory(), TakeEntityToTargetCargoEx() и TakeEntityToTargetInventory().