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

◆ TransferItemProperties()

static void TransferItemProperties ( EntityAI source,
notnull EntityAI target,
bool transfer_agents = true,
bool transfer_variables = true,
bool transfer_health = true,
bool exclude_quantity = false )
staticprotected

will transform variables, agents and other local scripted properties as well as any relevant non-scripted properties like health

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

270 {
271 ItemBase target_ib = ItemBase.Cast(target);
272
273 if (transfer_agents && target_ib)
274 target_ib.TransferAgents(source.GetAgents());
275
276 if (transfer_variables)
277 MiscGameplayFunctions.TransferEntityVariables(source, target, exclude_quantity);
278
279 if (GetGame().IsServer() || !GetGame().IsMultiplayer())
280 {
281 if (transfer_health)
282 {
283 TransferEntityHealth(source,target,{"Health"});
284 }
285 }
286 }
static void TransferEntityHealth(EntityAI source, EntityAI target, array< string > healthTypes=null, bool transferZoneDamage=true)
Определения MiscGameplayFunctions.c:386
Определения InventoryItem.c:731
proto native CGame GetGame()

Перекрестные ссылки GetGame() и TransferEntityHealth().