Advanced Sessions Plugin

How can you update a value for one of the extra settings? As a practical example let say you have this:

image

When editing I tried to do the following:


On the host side the value for Code does get updated to the new random string when calling

image

But unfortunately on client side it still gets the original value which means that this isn’t the way to do it, so how is it the correct way to do it?

Also @mordentral, is it possible to add a Make Literal Session Property Array String (/the other types)? Right now I can kinda simulate an array by adding a separator between the values, but having an array would be better for working with the value.

Thank you for the plugin!

//Edit1: After some more testing the Extra Settings values do get changed for the session itself, only that the changes are not replicated automatically to everyone, but new players that join the session will have the updated values.

//Edit2: I tired to add inside the controller the function that changes the value and be called on each player controller, but still the same, the value does not change on connected clients, only on new clients.

So I guess one way to solve this problem would be to save those settings as variables inside the Game State and when the host changes some settings related to the session, change the variables inside the Game State as well, to reflect the new changes.

One situation is that you add a password for the session and give the option to change the password once the session is started. You will save that password as a Make Literal Session Property String inside the Extra Settings but also inside the Game State. When a player wants to join the session you will check the password from Extra Settings with what he/she is giving. If it is correct then he/she can join. Now when the host changes the password, you will update the value inside the session Extra Settings which in turn will be updated for new players that join, but also update the value inside Game State. This value will be used by the rest of the players so they have an option to share the password for the session as well, and not only the host.

Join session isn’t my node (it comes with the engine), neither is any of the subsystem itself. Advanced sessions just exposes functions from the default engine subsystem to BP that were c++ only before.

The log is how epic prints out events from that kind of thing, and its where they throw messages about their node. I don’t think the actual interface even passes up a fail reason anyway to their join node so it couldn’t pass it out to begin with without engine modifications.

Had same issue, turns out I had to use 4.26 Online subsystem steam - finished settings for DefaultEngine.ini file , while my project is on 5.3.2 . Doesn’t makes sense to do so , but it worked for me .

I use Advanced session creat session in steam and i sure i all most setting in steam and network are already,but why i ping between 2 personal compuater request 9999 alwas

Steam auth has to be enabled for correct ping

Hi, i have a problem, for some reason my Find Session Advanced does not work, i have my create session, i have listen in open level, i installed everything by guides, i have steam id set to 480 and package as development, i use ue5.3.2.

@mordentral

Do you know why the PlayerState becomes invalid when connecting to a level during seamless server travel? (via internet dedicated server on Steam).

I have 2 games each with their own steam_appid and setup the same exact way. One connect and the other doesn’t.

If I close Steam on the client and run the server with -nosteam it will connect through the LAN (I only check UseLAN in CreateAdvancedSession when steam is disabled). So the issue is connecting to dedicated server over the internet.

Like I mentioned, the one game connects with no issue over the internet, but the second is a card game that has a very fast startup time gets the DestroySession - Invalid player state error.

Are you destroying the previous session after it has started transitioning?

No, the only Destroy Session is called when logging out

I searched for all DestroySession calls and found this…

Actually I was destroying the session, The EventEndPlay was being called.

The game that was working I had a switch

So the issue was the EventEndPlay called on LevelTransition was destroying the session.

Thanks for pointing me in the right direction.

Is the on invite accepted and received events not called when using EOS?
I have my game instance inheriting from advanced friends game instance, but no luck so far.

Does anyone have this set up succesfully? :slight_smile:

Depends on the subsystem you are using I would assume. Its a subsystem event that the backend code has to be calling.

1 Like

Yeah, I am using the default EOS subsystem plugin from Epic.
I’ll check it out tomorrow if they even have that implemented, otherwise I am moving to Steam haha.

2 years later, I got caught by that trap.
Thanks for the tip !

Hi,
I copied the two files (AdvancedSessions and AdvancedSteamSessions) from version 3.2.1 to the parent folder of my project. When I launch my project which is also on the 3.2.1 engine a message tells me that the file is not compatible with this version. (I tried a force rebuild but I was never able to open my project again) What did I do wrong? Thanks

I found the answer to my question, I’m on Mac. I had to recreate a blank C++ file in the plugin folder and it works

Could you specify on what C++ file it was? I am going through the same problem.

Thanks in advance.

I’m trying to use this to filter dedicated servers on a LAN, and I’m not having any luck finding anything even with an unfiltered find sessions.

Here’s my Game Mode BP setup:

If Dedicated Server->Create Advanced Session. Use LAN is True, Start After Create is True. And the log is showing successful creation of the session.

But when I start up the client and it does the Find Advanced Session, it gets an empty array. Am I missing something, or does this just not work with LAN?

[edit]Just tried packaging Client and Server builds and still getting the same results.

[edit2]Ok, I can’t even get this to work with a Listen server. Regular Create and Find session work as expected when using a Listen server, but trying to use the Advanced session nodes with the Advanced GameSession consistently returns no sessions.

[edit3] As far as I can tell Start Session is never actually getting called, either when setting Start After Create to true in Create Advanced Session, or when setting it to false and dropping in Start Advanced Session after On Success for Create Advanced Session. I’ve tried adding logging into OnStartCompleted of StartSessionCallbackProxyAdvanced.cpp, and it just never logs anything.

Turn on UseLobbiesIfAvailable, should be on by default, you turned it off, its what listen servers in engine use on most subsystems by default.

I figured it out. It was actually that ‘Should Advertise’ was set to ‘false.’ I feel like if ‘Use LAN’ is true, ‘Should Advertise’ should just automatically be treated as true. I don’t think there are a ton of people hosting invite only games at their LAN parties.