Advanced Sessions Plugin

So it looks like steam is not setting the rich presence info “Joinable” correctly. bIsJoinable in Presence Info is never true, despite the join game option being available on steam itself. Has anyone else worked around this yet?

Update: Turns out UE4 never sets the Joinable presence info to true and its up to us. I ended up creating delegates for all of the session events in my game instance, along with some helper functions for working with steamworks on its own and got it all working. If you throw AdvancedSessions on github I’d be more than happy to help work on some Advanced Presence stuff that’d make all of this alot easier. Here’s the helper function I made, it requires you to include Steamworks in your project build file and the relevant header files in your game instance. The basic idea is to set Joinable to true after a successful JoinSession, CreateSession or StartSession, then set it to false on End/Destroy session. You’ll probably want to periodically check if the player count is reached in the session and set it back to false for all connected players.



bool UCGameInstance::SetRichPresence(FString Key, FString Value)
{
	ISteamFriends* SteamFriendsInt = SteamFriends();
	if (SteamFriendsInt != nullptr)
	{
		if (SteamFriendsInt->SetRichPresence(TCHAR_TO_UTF8(*Key), TCHAR_TO_UTF8(*Value)))
		{
			return true;
		}
	}

	return false;
}


1 Like