kumarjac: This indicates a failure in replication relationships as player full inventory should be synchronized always if player exists on the remote
Do not check for action validity on remotes or when performing through juncture. Juncture locks guarentee the item is safe to interact with and the server has validated the command at this point. Checking at this point is both wasteful and can result in a failure which leads to desync
Do not check for action validity on remotes or when performing through juncture. Juncture locks guarentee the item is safe to interact with and the server has validated the command at this point. Checking at this point is both wasteful and can result in a failure which leads to desync
Do not check for action validity on remotes or when performing through juncture. Juncture locks guarentee the item is safe to interact with and the server has validated the command at this point. Checking at this point is both wasteful and can result in a failure which leads to desync
Do not check for action validity on remotes or when performing through juncture. Juncture locks guarentee the item is safe to interact with and the server has validated the command at this point. Checking at this point is both wasteful and can result in a failure which leads to desync
1230 {
1232
1235
1238
1239 bool skippedSwap = false;
1240 bool success = true;
1241
1246 ctx.Read(skippedSwap);
1247
1248 #ifdef ENABLE_LOGGING
1250 {
1252 }
1253 #endif
1254
1256 {
1257 if (skippedSwap)
1258 {
1259 #ifdef ENABLE_LOGGING
1261 {
1263 }
1264 #endif
1265
1266
1267
1268
1269
1270
1271 }
1272 else
1273 {
1275
1276 #ifdef ENABLE_LOGGING
1278 {
1280 }
1281 #endif
1282
1283 Error(
"[syncinv] HandleInputData remote input (cmd=SWAP) dropped, item not in bubble");
1284 }
1285
1286 return true;
1287 }
1288
1291
1296 {
1297#ifdef ENABLE_LOGGING
1299 {
1301 }
1302
1304 {
1306 }
1307#endif
1308
1311
1313 {
1314 success = false;
1315 }
1316 else
1317 {
1318 return true;
1319 }
1320 }
1321
1326 {
1327#ifdef ENABLE_LOGGING
1329 {
1331 }
1332
1334 {
1336 }
1337#endif
1338
1341
1343 {
1344 success = false;
1345 }
1346 else
1347 {
1348 return true;
1349 }
1350 }
1351
1356 {
1357#ifdef ENABLE_LOGGING
1359 {
1361 }
1362
1364 {
1366 }
1367#endif
1368
1371
1373 {
1374 success = false;
1375 }
1376 else
1377 {
1378 return true;
1379 }
1380 }
1381
1384
1386 {
1387 ClearInventoryReservationEx(dst1.
GetItem(), dst1);
1388 ClearInventoryReservationEx(dst2.
GetItem(), dst2);
1389 }
1390
1395 {
1396 #ifdef ENABLE_LOGGING
1397
1398 #ifdef DEVELOPER
1399 DumpInventoryDebug();
1400 #endif
1401
1403 {
1405 }
1406 #endif
1407
1409 {
1410 success = false;
1411 }
1412 else
1413 {
1415 return true;
1416 }
1417 }
1418
1420 {
1423 }
1424
1426 {
1428 return true;
1429 }
1430
1433 {
1436 {
1437 #ifdef ENABLE_LOGGING
1439 {
1441 }
1442 #endif
1443
1445 }
1447 {
1448 #ifdef ENABLE_LOGGING
1450 {
1452 }
1453 #endif
1454
1458 return true;
1459 }
1460 else
1461 {
1462 #ifdef ENABLE_LOGGING
1464 {
1466 }
1467 #endif
1468
1471 return true;
1472 }
1473 }
1474
1476 {
1477 ClearInventoryReservationEx(dst1.
GetItem(), dst1);
1478 ClearInventoryReservationEx(dst2.
GetItem(), dst2);
1479 }
1480 else
1481 {
1484 }
1485
1486
1488 {
1489 #ifdef ENABLE_LOGGING
1491 {
1493 }
1494 #endif
1495 return false;
1496 }
1497
1498 #ifdef ENABLE_LOGGING
1500 {
1502 }
1503 #endif
1504 if (success)
1505 {
1506 bool isNotSkipped = LocationSwap(src1, src2, dst1, dst2);
1507
1510
1512 }
1513 return true;
1514 }
void syncDebugPrint(string s)
InventoryValidationResult
InventoryValidationReason
void EnableMovableOverride(EntityAI item)
bool SwapCheckExclusionMaskLocal(notnull InventoryLocation src1, notnull InventoryLocation src2, notnull InventoryLocation dst1, notnull InventoryLocation dst2)
Local, checks only stuff that is in guaranteed sync.
bool PlayerCheckRequestSrc(notnull InventoryLocation src, float radius)
void RemoveMovableOverride(EntityAI item)
DayZPlayer GetDayZPlayerOwner()
bool PlayerCheckSwapItemsRequest(notnull InventoryLocation src1, notnull InventoryLocation src2, notnull InventoryLocation dst1, notnull InventoryLocation dst2, float radius)
bool TryAcquireTwoInventoryJuncturesFromServer(notnull Man player, notnull InventoryLocation src1, notnull InventoryLocation src2, notnull InventoryLocation dst1, notnull InventoryLocation dst2)
bool ClearJunctureEx(Man player, notnull EntityAI item)
static void InventoryMoveLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
const int c_InventoryReservationTimeoutShortMS
static bool CanForceSwapEntitiesEx(notnull EntityAI item1, InventoryLocation item1_dst, notnull EntityAI item2, out InventoryLocation item2_dst)
const float c_MaxItemDistanceRadius
anti-cheats
script counterpart to engine's class Inventory
proto native bool IsValid()
verify current set inventory location
static string DumpToStringNullSafe(InventoryLocation loc)
bool ReadFromContext(ParamsReadContext ctx)
proto native EntityAI GetItem()
returns item of current inventory location
InventoryValidationResult m_Result
InventoryValidationReason m_Reason
static bool IsSyncLogEnable()
static bool IsInventoryMoveLogEnable()
DayZPlayerInstanceType
defined in C++
proto native DayZPlayerInstanceType GetInstanceType()
proto native CGame GetGame()
void Error(string err)
Messagebox with error message.