5345 {
5346 if (
g_Game.IsMultiplayer())
5347 {
5349 switch (t)
5350 {
5352 return false;
5358 return true;
5359
5360 if (LogManager.IsSyncLogEnable())
syncDebugPrint(
"[syncinv] " +
GetDebugName(
this) +
" STS=" + GetSimulationTimeStamp() +
" NeedInventoryJunctureFromServer item=" +
Object.GetDebugName(item) +
" currPar=" + currParent +
" newPar=" + newParent);
5361
5362 bool i_owned = GetHumanInventory().HasEntityInInventory(item);
5363
5364 bool cp_owned = false;
5365 if (currParent)
5366 cp_owned = GetHumanInventory().HasEntityInInventory(currParent);
5367
5368 bool np_owned = false;
5369 if (newParent)
5370 np_owned = GetHumanInventory().HasEntityInInventory(newParent);
5371
5372 bool all_owned = i_owned && cp_owned && (np_owned || (newParent == null));
5373 if (LogManager.IsSyncLogEnable())
syncDebugPrint(
"[syncinv] " +
GetDebugName(
this) +
" STS=" + GetSimulationTimeStamp() +
" NeedInventoryJunctureFromServer=" + !all_owned +
" i_pwn=" + i_owned +
" cp_pwn=" + cp_owned +
" np_pwn=" + np_owned);
5374
5375 return !all_owned;
5376 default:
5377 Error(
"[syncinv] unsupported instance type t=" + t);
5378 break;
5379 }
5380 }
5381 return false;
5382 }
void syncDebugPrint(string s)
override string GetDebugName()
DayZPlayerInstanceType
defined in C++
proto native DayZPlayerInstanceType GetInstanceType()
void Error(string err)
Messagebox with error message.