From 52a881b20dea6475fed8b6f0ff0d4d95ae377ac7 Mon Sep 17 00:00:00 2001 From: Mikeeeyy Date: Sun, 5 Apr 2015 19:05:12 +0100 Subject: [PATCH] [FIX] Inventory wiping dayz_Magazines isn't always set before syncing the character, and especially considering this is just on a loop makes it very unreliable. If you input an empty array to the server_playerSync then it will wipe your backpack and weapons aswell. Noticed this bug when players were complaining about it since I switched completely over to extDB. I've taken a look at the HiveExt.dll source and I'm pretty sure I found a check in there to see if the array is empty, which is still a hacky fix for this. I honestly wonder what the devs of DayZ were doing when they made this mod, honestly the coding is horrendous. I honestly just feel like making my own version of it from scratch sometimes. Rant over... sorry lol. Back on topic, using magazines player won't record the clip count in a magazine, but the only time that actually seems to be saved is when the gear dialog is closed because that's the only time you can record it using the gearIDC commands. --- SQF/dayz_code/system/player_spawn_2.sqf | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/SQF/dayz_code/system/player_spawn_2.sqf b/SQF/dayz_code/system/player_spawn_2.sqf index 6f38f5b1a..2e220977f 100644 --- a/SQF/dayz_code/system/player_spawn_2.sqf +++ b/SQF/dayz_code/system/player_spawn_2.sqf @@ -206,11 +206,10 @@ while {true} do { //Save Checker if (dayz_unsaved) then { if ((time - dayz_lastSave) > DZE_SaveTime) then { - PVDZE_plr_Save = [player,dayz_Magazines,false,false]; + PVDZE_plr_Save = [player,magazines player,false,false]; publicVariableServer "PVDZE_plr_Save"; dayz_unsaved = false; dayz_lastSave = time; - dayz_Magazines = []; }; };