Jump to content
Sign in to follow this  
galzohar

Massive desync in a multiplayer mission for no apparent reason

Recommended Posts

I have absolutely no idea why this mission causes desync when played with many players (had ~23 on when we tried this). Desync was so massive that people were running in place and couldn't get in/out of vehicles most of the time. When playing alone there is absolutely no desync. I even switched between all units and got in/out of all vehicles and most positions in those vehicles. I'm not sure but the desync *might* only happen once people actually get in vehicles but it could just be something that happens a bit after mission starts. In any case it does take a short time before any desync starts happening - You don't get any desync on the first few seconds of the mission at the very least.

Trying to narrow the problem down, I checked which lines of code are actually unique to this mission and are not used in other missions. The only scripts I use there that I hadn't successfully used in other missions are:

1. reinforce.sqf

2. groupbuildingpos.sqf

3. Some of init.sqf (specifically the spawning of the hummerbulance)

4. init commands of enemy units (the init lines of friendly units were all successfully used in other missions. The doStop command does cause some RPT spam but does not cause desync as I used it successfully before in other missions and even though it was causing spam the missions were working perfectly smooth with 25 players. In any case beta2 is up on the test server without the RPT spam though this most likely has nothing to do with the problem).

All other scripts were successfully used before in other missions with 15-25 players (namely groupmarker.sqf, unitmarkers.sqf, briefing.sqf, assigngear.sqf, populateX.sqf, viewdistance.sqf, setviewdistance.sqf, endhandler.sqf, UPS.sqf and most of the init.sqf).

Here are the parts of the init.sqf that are unique to this mission:

if (isServer) then
{	
[.....]

cmdVeh = "HMMWV_Ambulance" createVehicle markerPos "ambulancePos";
cmdVeh setDir 0;
cmdVeh setPos markerPos "ambulancePos";
[cmdVeh] execVM "populatecmdveh.sqf";
publicVariable "cmdVeh";
onPlayerConnected "
	[.....]
	publicVariable 'cmdVeh';
";

execVM "reinforce.sqf";
};

if (!isDedicated) then
{
[] spawn
{
	waitUntil {!isNil "cmdVeh"};
	[cmdVeh] execVM "populatecmdveh.sqf";
	[cmdVeh, "CMD ambulance", "b_hq", WEST] execVM "groupmarker.sqf";
};
};

.....

sleep 1;
hint "Change view distance on one of the flags";

Download of the version without the doStop command on US soldiers (so that you don't get clutter in the RPT file, though I'm pretty sure this has nothing to do with the actual desync):

http://www.filefactory.com/file/b09950b/n/ace_co_30_fortified_base_beta2.FDF_Isle1_a.pbo

If anyone has any ability to point out at something that may be causing such massive desync, please let me know.

Addons:

- Latest ACE as of today, using M1A1s, Bradley IFVs, cobras and US army soldiers.

- Podagorsk

- MAP_EU.

Share this post


Link to post
Share on other sites

I still hadn't got the chance to test this thoroughly since it requires a critical mass of players, but it seems to have something to do with the flags that have an action menu to choose 1 of many options for view distance. What's weird though is that I've played a no-AI PvP mission with those exact flags (except view distance only went up to 4k rather than 5k) and it worked fine with 16 players, so it might have something to do with having those flags and AI at the same time. Then again it might not have anything to do with them...

Any ideas would be much appreciated.

Share this post


Link to post
Share on other sites

Did you place the Functions module? Forgetting that can sometimes cause a terrible lag.

Share this post


Link to post
Share on other sites

What causes major lag if you don't place the functions module? I thought you only need it if you actually use stuff from it?

Share this post


Link to post
Share on other sites

Still can't find the problem. I thought it was the view distance flag poles that have an action menu on them, but after removing all of them there was still desync. I also changed it so everyone start inside their vehicle gunner/driver/commander/cargo slot and after that change it seems like the desync happened immediately rather than a few seconds into the game, so it *could* be vehicle-related (mission uses M1A1s, Bradleys, Cobras and a Hummerbulance).

With ~10 players no desync is seen (though then again I'm not sure they got into the vehicles). 20 players got the desync almost instantly with players starting in the vehicles (and a few seconds into the game when the players moved in by themselves, though this may or may not just happened randomly as I obviously couldn't repeat the test).

Share this post


Link to post
Share on other sites

I am still unable to resolve the issue, and received it again in a new mission that has very little in common with the original. When loading the mission by myself the server FPS is actually very high (~40) and the bandwidth usage is very low (10-40Kbps as opposed to 100-300Kbps in other missions that do work fine).

The only scripts that are in common between the missions:

- Assign gear script

- Breifing

- endhandler script

- group marker and unit marker scripts

- spectator script

- UPS (though one uses UPS and the new one UPSMON)

All scripts have been used in other many missions and were working perfectly fine.

Units that are used in both missions:

- Shilka

- T-72B

- M1A1 HC

- Cobra

So if anyone knows of any desync-related issues with any of those units in ACE please let me know. Could it have something to do with the flares? I remember on another mission we played with UH-1Ys as soon as one of them popped flares the server started to give everyone insane desync (though it got better after ~2 minutes which is not the case in in the 2 missions I'm talking about here). However I have doubts it's the flares, as the desync happens before the helicopters even have a time to get anywhere near the action and sometimes before they even have time to take off.

Here's the new mission causing this issue:

http://www.filefactory.com/file/b0e9g69/n/ace_co_24_armored_forest.chernarus.pbo

Share this post


Link to post
Share on other sites

Could very well be flares or tank anti-missile defenses in ACE. Those have code screaming away in the background looking for incoming objects - does not matter if near an enemy or not.

Share this post


Link to post
Share on other sites

Does the T-72B have any of those? Because I do have a quite a few T-72Bs around in those missions, and only 2 cobras and 1 M1A1.

But then again, I remember getting desync a while ago in a mission that only had 2 UH-1Ys for vehicles as soon as a flare was launched (against an RPG nonetheless as the enemy had no other rockets in their arsernal).

In any case this never happens with a low player count.

Edited by galzohar

Share this post


Link to post
Share on other sites

is this hosted MP? If so it depends on your upload speed. I believe you need at least 50kb per player upload.

Share this post


Link to post
Share on other sites

Dedicated server that can handle a lot more than 20 players and a lot more AI than these missions have.

Share this post


Link to post
Share on other sites

Still looking if anyone managed to successfully use any of those vehicles in missions with a large (20+) player count.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×