Closed deBearN closed 2 months ago
Hello,
Thanks for the report
Base on your rpt, it looks like you didn't enable the feature or this is return false
: https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/core/fnc/eh/server.sqf#L82
To exclude those hypotheses please change those line https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/core/fnc/eh/server.sqf#L80-L86 to:
[format ["Auto save enabled? %1", btc_p_auto_db], __FILE__, [false, btc_debug_log, false]] call btc_debug_fnc_message;
if (btc_p_auto_db) then {
addMissionEventHandler ["HandleDisconnect", {
[format ["HandleDisconnect triggered, remaining connected players: %1", allPlayers - entities "HeadlessClient_F"], __FILE__, [false, btc_debug_log, false]] call btc_debug_fnc_message;
if ((allPlayers - entities "HeadlessClient_F") isEqualTo []) then {
[format ["Saving in progress, who triggered the save %1", _this], __FILE__, [false, btc_debug_log, false]] call btc_debug_fnc_message;
[] call btc_db_fnc_save;
};
}];
};
The dev server (https://github.com/Vdauphin/HeartsAndMinds/discussions/1098) is using this feature without issue, you can give it a try yourself
Also why not using parameters:
Cheers
11:27:19 (0:02:10) fnc\slot\serializeState - Bear 11:27:19 (0:02:10) fnc\slot\serializeState - [[8307.4,10088.5,75.7807],138.8,[[["arifle_MSBS65_GL_sand_F","","acc_flashlight","op 11:27:19 tic_Holosight_blk_F",["30Rnd_65x39_caseless_msbs_mag",30],[],""],[],["hgun_P07_khk_F","","","",["16Rnd_9x21_Mag",17],[], 11:27:19 ""],["U_C_IDAP_Man_TeeShorts_F",[["ACE_fieldDressing",1],["ACE_packingBandage",1],["ACE_morphine",1],["ACE_tourniquet",1 11:27:19 ]]],["V_PlateCarrier1_wdl",[["16Rnd_9x21_Mag",2,17],["HandGrenade",2,1],["SmokeShell",1,1],["SmokeShellGreen",1,1],["Che 11:27:19 mlight_green",2,1]]],["B_CombinationUnitRespirator_01_F",[]],"H_Booniehat_tan","G_AirPurifyingRespirator_01_nofilter_F", 11:27:19 [],["ItemMap","","ItemRadio","ItemCompass","ItemWatch","NVGoggles_INDEP"]],[["ace_arsenal_insignia","ACE_insignia_logo"] 11:27:19 ]],"",false,"{""ace_medical_openwounds"": {}, ""ace_medical_bloodpressure"": [80, 119], ""ace_medical_ivbags"": null, "" 11:27:19 ace_medical_inpain"": false, ""ace_medical_medications"": [], ""ace_medical_tourniquets"": [0, 0, 0, 0, 0, 0], ""ace_med 11:27:19 ical_heartrate"": 79.6623, ""ace_medical_pain"": 0, ""ace_medical_bloodvolume"": 6, ""ace_medical_stitchedwounds"": {}, 11:27:19 ""ace_medical_fractures"": [0, 0, 0, 0, 0, 0], ""ace_medical_triagelevel"": 0, ""ace_medical_bodypartdamage"": [0, 0, 0, 11:27:19 0, 0, 0], ""ace_medical_hemorrhage"": 0, ""ace_medical_occludedmedications"": null, ""ace_medical_triagecard"": [], ""a 11:27:19 ce_medical_bandagedwounds"": {}, ""ace_medical_peripheralresistance"": 100, ""ace_medical_painsuppress"": 0, ""ace_medic 11:27:19 al_statemachinestate"": ""Default""}",B Alpha 3-5:1,[0,0]] 11:27:19 (0:02:10) fnc\eh\server - HandleDisconnect triggered, remaining connected players: [B Alpha 3-5:1]
How is this even possible? i'm gonna put the other 2 logs i did here and soon a video of me doing all that
I managed to trigger the save by closing the game via task manager, which sent "me" (the player in the server) into losing connection, when re-opening the game and trying to join it gave me connection failed which kicked the "player" of me in there losing connection and it saved, perhaps it's a delay between the player leaving and the script?
Thank you for the detailed report, I think A3 do not clean the allPlayers
variable fast enough for the mission so the H&M still think the player is connected
Would you like to test the above linked fix?
testing right now
It seems to have worked in the default Altis mission, great, gonna test this in my modded mission
It did indeed work thank you
Thanks for the test Let's keep it open until the PR is merged!
Arma 3 Version:
2.16.152172
(stable) CBA Version:3.171
(stable) ACE3 Version:3.17.1
(stable) Hearts and minds Version:1.24.2
(stable)Mods:
Description:
My player base mentioned in the Main Op day (after a restart) that the progress they made in a recon op wasn't saved, i checked the Log menu in the map where parameters shows up, the option Auto savegame when all players disconnected was set to 1, to test this i went through a multitude of ways to test it, moved, changed equipment and placed an object through zeus, left the server (i was the only one in) waited 5 minutes to be sure then closed the server and opened it again, it was back in the last moment i manually saved without the zeus placed object and the other changes i made.
I Changed to the normal Altis H&M mission found here while replacing it with our params file, even forked the depo to compare if there could be an issue with our version, apart from the changed options values and the city distance that i tweaked to have values up to 1500m and 2000m radius it was the same, then i moved, changed equipment and placed an object through zeus, i just disconnected and connected, sure enough everything was in place, my last position was saved with equipment, but after i disconnected and restarted the server like last time, it didn't save
I removed all of our mods, ran only cba and ace3 and did the same test again, and the problem repeated itself
While writing this bug report i just in case tested it again, and it worked, i was baffled, tested again it didn't work, then again, then again, and it worked some times and didn't some other times, and after it did save, which means after a server restart i was in the new position with the new equipment if it didn't worked next time i was back to my original position, i tried finding logic in it but i can't
Steps to reproduce:
Add mission file: Mission.zip RPT log file: Logs.zip