Player persistence failing for first player on dedicated server on missions with lots of data

  1. 7 years ago

    I'm close to releasing a SP/COOP mission on Tanoa and it relies heavily on player persistence (there are consequences if you are spotted by a certain side, meaning getting anywhere takes ages). The issue I'm having now, having nearly completed this scenario, is that whenever there is persistent data present, the mission takes a long time to load and when it does, it skips the briefing screen. This itself isn't an issue but it completely breaks player persistence. The only way around it is to autoinitialise the server, which breaks half the scripts in the mission.

    My feeling is that it's a module load order issue relating specifically to the Data module. On missions that have a lot of persistent data (for me, this includes pretty much standard suite of ALiVE modules on anything larger than Stratis), the game starts (as in, you can hear environmental sounds, footsteps, people shouting orders) well before the player has left the loading screen. The map briefing screen may flash up, then it jumps back to loading and stays there for a while, until the mission actually starts properly. By which time, player persistence has lost its window of opportunity to work and so the player starts at the default starting position with the default kit. Change the mission name (and get rid of the persistent data associated with it), and the mission will load absolutely fine.

    Using auto-init on TADST, persistence works perfectly on all fronts so the Data module itself is working fine, but like I said, unfortunately this breaks the mission itself.

    It's an issue I can recreate completely vanilla and near-universally with any mission that has a lot of data saved. I did have another thread a while back about a similar issue but have no idea where it's gone!

    So, two questions really. First, is this affecting anyone else?

    Second, is there a workaround to make sure the player data is loaded later on in the loading queue?

    Thank you all again for all your awesome work on this mod, it's improving at an astonishing rate.

  2. Edited 7 years ago by HeroesandvillainsOS

    Is the briefing a scene that plays after the game loads (in the game world)? I haven't dug into making genuine intro scenes aside from very basic text-title intros, but I have had issues with triggers firing before the mission loads, etc. Which I now set to a 13 second sleep timer which seems to be just long enough for ALiVE to initialize on smaller maps.

    Perhaps you could set the briefing to a trigger rather than a script and just put a sleep on the trigger?

    Anyway, I know the exact loading sequence you're talking about. It happens to me on big (high objective) maps like Altis.

    EDIT: I also wouldn't be surprised if the Author is not a value error you mentioned still experiencing isn't just making the whole initializtion process worse for you either. That error when I had it extended my intiial loads times by a lot (and in some cases - which I can elaborate on if you want - breaks the entire initialization process completely).

  3. I got rid of all the errors like that, spent ages trying to fish them out! There's probably quite a few left over though. The briefing screen is basically just the map screen you get when you play a single player mission right at the start, you have to click continue to get to the mission itself.

    It's a problem that happens vanilla with nothing fancy running at all, I've pretty much narrowed it down now to purely the amount of data that ALiVE has to load at the beginning of the mission. If it's a small mission with few AI, player persistence works fine and so does the briefing screen (which doesn't really matter too much, but player persistence will only work on a newly restarted server when the briefing screen does load). With a big mission with lots to persist, then player persistence doesn't initialise properly. This is with many different variations of description.ext and init.sqf. Basically, it's with missions that fundamentally should work perfectly with ALiVE (and do, ignoring this issue).

    To reproduce, make a really simple mission on a large map (like Tanoa or Altis) and have two OPCOMs with around 60 objectives and 400 units each, have civpop and placement modules, and all the basics like player options, data and C2ISTAR. Set it up on a dedicated server, start the server with autoinit off, then log in, play for a couple of minutes, save and exit. The close the server down, start it up again, and rejoin.

    I can make a sample mission to send out when I get back to my PC.

  4. I have a vanilla mission on Altis with way too many objectives (about 110 per OPCOM so near 220 total which is why I haven't released it) and the pre-play map screen where the briefing would be is fine. That missions is vanilla, plus Spyder Addons.

    Also in my released missions which use a crap ton of mods and scripts, which average around 85+ objectives a piece, the briefing screen is just fine too and those missions actually have diary record briefings.

    That said I haven't tested in a dedicated server environment recently. Just SP and/or LAN. Is this only happening on a dedi?

    Errors will most definitely make strange stuff happen on initialization. But your report example wouldn't have those I don't think.

    For various reasons reported today I need to hop on my server to get a look-see at how ALiVE and Spyder Addons are working in that kind of environment. I'll let you know what I see later. Strange stuff.

  5. Yeah, it's purely a dedicated server issue as it's the persistence data itself that causes the mission to skip the briefing and player persistence.

    If you are able to actually dude, could you try setting one of your missions on a dedicated server, starting the server with autoinit off, then log in, move somewhere and drop your weapon or change it or something, then save and exit, close the server down, start it up again, and rejoin?

    No worries if not! But at least if someone else can reproduce it then I know I'm not going nuts.

  6. Edited 7 years ago by incontinenetia

    Just to confirm, if you do this, the behaviour you should see when joining the mission once again is this:

    1. Longer loading screen compared to when no data is present.

    2. No map screen or a map screen that flickers in and goes back to the loading screen then gets skipped entirely.

    3. Player persistence failed (other persistence should be alright) when in mission.

    On another smaller mission, the map screen flickers on and back to the loading screen for a while, then back to the map screen. Player persistence always succeeds when you have to click continue before mission start and it frequently (if not always) fails when it takes too long to load and that map screen is skipped.

  7. Ok. So just so I'm clear, the first time you play the mission the briefing plays fine, but when you load a persistent save is when it skips the briefing screen? Any other odd bahavior I should look for? Is everything else mission related persisting ok or is it totally messed up? Any additional details would help me a lot.

    I usually keep the auto-init checkbox unchecked in TADST. But I am NO EXPERT for advanced TADST use. If I need to do anything special other than leaving that box unchecked let me know.

  8. Edited 7 years ago by HeroesandvillainsOS

    Thanks for the new post ^^^

    It's player persistence (ammo, weapons, gear, etc). Got it. I will most definitely check.

  9. Thanks buddy!! Really appreciate the help. Yep it's ONLY when persistent data is present that this issue happens. Really, the briefing screen isn't an issue at all, it's just the clearest indication that player persistence is about to fail. For me, the correlation is near 100%.

  10. Could you post a rpt from a mission you loaded, preferably with the data module debugged? @SpyderBlack723 should anything else be debugged other than that?

    I can't read them but I'd assume one of the Devs would like to see a rpt on this.

  11. Edited 7 years ago by incontinenetia

    I'm away from my PC today but will post one when I'm back soon.

    I have a feeling this could be a pretty universal issue though as my usage is fairly niche (SP on dedi for performance and persistence). Would love to iron this out though as I have a load of scenarios I've been working on for months tailored specifically for this usage and I'd like to release them but I haven't been able to get past this player persistence issue since the CBA changes just after EDEN.

    I've started missions from scratch and even changed PCs since then and the same issue, each time, even with brand new modules with each ALiVE update, player persistence has failed on anything other than the most basic Stratis-sized missions. Each time, auto-init solves all persistence problems it but breaks mission scripts. Really want to get these missions out there!

  12. Edited 7 years ago by HeroesandvillainsOS

    If player persistence isn't working than there's a problem. The amount of objectives you say you're using isn't so high that I'd imagine a lot of groups aren't using the same or more (I personally use quite a bit more). And considering you can duplicate this with vanilla, I'd say there's a good chance something is wrong.

    If you could get whatever Spyder recommends shared here when you have a sec that would be great. I only have time tonight to launch a mission on a dedi, look over a few things, and load it back. I have a date with Phantom's Baphomet mission later as I promised him I'd play it. :)

    Otherwise, I can try to get a full repro and rpt tomorrow if you don't beat me to it.

  13. Yeah of course, thanks for your help regardless of whether you get the chance to repro. Can't be a biggie given that everything works fine without data. And it could always be that I place Data down as one of my first modules. Who knows!

  14. Edited 7 years ago by incontinenetia

    Funnily enough, you can actually see similar behaviour in this video from the Display Map Intel: Working on dedicated servers? thread. See how the mission loads up, then starts, then jumps back into the loading screen? You don't see the briefing screen in the editor but that behaviour (in my experience) always correlates with player persistence being broken for the first person starting a mission on a dedicated server. That's likely because of an error in the last version, but it helps demonstrate roughly what I'm referring to when I say it jumps back to the loading screen after the mission has loaded.

  15. I know the exact skip you're referring to. I see it all the time. I guess only a Dev would know whether or not it could cause issues in and of itself though.

    I'm assuming the best way to isolate this would be vanilla + debug on the player data and data modules with a rpt capturing an attempted load of a mission but again, I'd prefer confirmation of exactly what they'd need debugged to determine what's messing with player persistence before trying to repro.

  16. Edited 7 years ago by incontinenetia

    Hold fire on this, seems I spoke too soon. My repro isn't quite working yet. Not sure quite why yet but I'll get something consistent that I can get going 100% and report back if it's anything to do with ALiVE. May just be that I forgot to replace a module since the last update. Standby!

    EDIT: Unfortunately, the repro is working. I just added another few playable units to my test scenario and it all went a bit loopy. Here's the RPT and mission files .

    Completely vanilla, made from scratch purely for this test, basic settings of most modules applied. Persistence saves fine but when the server is restarted and initialised by the client, it fails exactly in the manner described above for the initialising client - no briefing screen, sounds heard long before loading screen finishes, and no player persistence. Other modules' persistence is working however.

    I have verified that persistence data is saving fine; the mission loads perfectly when the server is auto-initialised. However, when the client prompts server init, player persistence (and only this as far as I can tell) fails.

    Steps to reproduce:

    1. Load up the scenario on dedicated server. Briefing screen will appear, mission will load fine.

    2. Wait a short while. Remove weapon and change positions. Server save and exit.

    3. Close server completely.

    4. Restart server making sure not to use auto-init.

    5. Join the server. This time, briefing will be skipped, much longer loading screen, sounds heard before the loading screen finishes, and player persistence will have failed.

    You can also verify that the mission itself is set up correctly by doing steps 1 - 3, then:

    4. Starting the server using auto-init (option next to persistent battlefield on TADST).

    5. Watching monitor to wait for the mission to initialise completely.

    6. Join the server. Player persistence will be working.

    Please let me know if I can do anything else to help narrow this down.

  17. Edited 7 years ago by incontinenetia

    Here's my second repro done with as much detail as I can muster. Produced this (slightly more complex) mission earlier on and have since run three tests on it. Basically, it's the usual array of modules just with a larger number of objectives and an asymmetric OPCOM with all persistence options set to on. The mission files are included in the dropbox link at the bottom. It has no scripts, was built in a sterile environment with no other mods, and had no previous saved data. Mission entirely produced by me just now using latest versions of ALiVE, Arma 3 and CBA.

    Test 1 (fresh mission name, no pre-existing data, no auto-init): Mission initialised at 12.23.19. Briefing screen appears at 12.24.23. Clicked continue and hint about player data loaded from ALiVE servers appears, everything works perfectly.

    Actions taken: moved to new location, dropped primary weapon on ground, placed test marker, moved nearby vehicle, placed second test marker on top of profile e174 in Gravia. Then logged into admin, server saved and exited at 12.28.07, save completes at 12.29.06. Shut down server completely.

    Stats:

    Time between mission init and briefing screen: 1 min, 4 sec.
    Data save duration: 59 sec.

    Test 2 (pre-existing data from Test 1, no auto-init): Mission initialised at 12.37.44. Goes into loading screen. At roughly 12.39.15 (+/- 4 seconds), during the load screen, environmental sounds begin (including footsteps and some distant shooting). Server RPT suggests this is during data loading and just after Player Options starts loading (although I'd ask a dev to confirm this as I'm no RPT expert). At 12.39.36, the loading screen finishes, map briefing flashes for a millisecond, and the hint about player data loaded from ALiVE servers does not appear.

    Observations: Markers are present at correct location, profile e174 is exactly where it should be, weapon left on ground is at correct position, the moved vehicle is at the place it was left at the end of Test 1. Time of day (I think) has persisted too. Player loadout and starting position however have failed and are the default for the character, despite these options being checked in the player options module. Essentially, all persistence has worked except for Player Persistence.

    Actions taken: Server shut down without saving persistence.

    Stats:

    Time between mission initialised and environmental sounds: 1 min, 31 sec.
    Time between mission init and loading screen ending: 1 min, 47 sec.

    Test 3 (pre-existing data, "persistent battlefield" and "auto-init" options checked in TADST settings):

    13.04.36: Read mission.
    13.05.45: ALiVE Global Timer Complete.
    13.06.21: Player joins.
    13.06.27: Loading screen finishes.

    Observations: Hint about player data loaded from ALiVE servers appears and everything works perfectly. Markers loaded, weapon left on ground, vehicle where it should be, e174 at exact position) however this time, the player has persisted too and is in the correct place and has no primary weapon as per the end of test 1.

    Conclusions

    I strongly suspect the persistence problem is caused by Player Persistence loading before the player is found in playable units. Previous tests I've run suggest that if player persistence doesn't load at the start, it won't save at the end, even if everything else does. So I could run Test 2 again, save and exit at the end, and then run Test 3, and the player persistence data that loads will be the original data from Test 1.

    A further, less clinical test I ran suggests that the longer SYS_DATA takes to load, the more likely this behaviour is to appear. So, for people with slower internet connections (mine is about 2mb/sec) or internet connections that are bottlenecked in some way, this issue is more likely. Furthermore, the more data there is to load and therefore the longer that loading takes place, the more likely this issue is to persist.

    Possible solutions:

    1. Make player persistence wait until the player is found in playableunits before initialising.

    2. Find a way to prevent the mission starting while the first player on server is still stuck in the loading screen. The best indicator of this is the first player on the server having to click "Continue" on the map screen before the mission starts.

    Edit: I'll post this on GitHub.

  18. Here are the RPTs and mission files for the tests above.

  19. Just curious, what does Auto Init do? Reading all this, it looks to me that for persistence to work in full, I'd need that checked within TADST at all times. Would that be an accurate interpretation of your results?

  20. Edited 7 years ago by incontinenetia

    Usually the server only actually starts loading the mission once the first player has joined. Auto-init overrides this and allows the server to load a mission before any players actually join, massively speeding up the load time of the first player to join the mission.

    As for whether you should use it, I think the above bug is dependent on two things: first, there being a lot of data, and second, the speed of the internet connect. Together these dictate how quickly SYS_DATA loads and therefore whether player persistence initialises at the right time. So, smaller missions with less persistent data and people with faster internet connections will experience the issue less.

    Short answer is: does player persistence work? If so, you're fine. If not, and all other persistence works, then try using auto-init.

  21. Newer ›
 

or Sign Up to reply!