mirror of
https://github.com/mordentral/AdvancedSessionsPlugin.git
synced 2025-12-10 08:03:14 +00:00
Compare commits
6 Commits
5.6-Locked
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
50c38e90ae | ||
|
|
31aab9f75e | ||
|
|
6f8760f96e | ||
|
|
8315e35a8f | ||
|
|
6462cd4c6f | ||
|
|
e576724b63 |
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"FileVersion": 3,
|
"FileVersion": 3,
|
||||||
"FriendlyName": "Advanced Sessions",
|
"FriendlyName": "Advanced Sessions",
|
||||||
"Version": 5.5,
|
"Version": 5.7,
|
||||||
"VersionName": "5.5",
|
"VersionName": "5.7",
|
||||||
"Description": "Adds new blueprint functions to handle more advanced session operations.",
|
"Description": "Adds new blueprint functions to handle more advanced session operations.",
|
||||||
"Category": "Advanced Sessions Plugin",
|
"Category": "Advanced Sessions Plugin",
|
||||||
"CreatedBy": "Joshua Statzer",
|
"CreatedBy": "Joshua Statzer",
|
||||||
|
|||||||
@@ -44,10 +44,15 @@ public:
|
|||||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = AdvancedVoiceInterface)
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = AdvancedVoiceInterface)
|
||||||
bool bEnableTalkingStatusDelegate;
|
bool bEnableTalkingStatusDelegate;
|
||||||
|
|
||||||
|
// If true we will auto join a session we have accepted in the overlay.
|
||||||
|
// This can get in the way of Beacon Sessions, you may want to disable it.
|
||||||
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = AdvancedFriendsInterface)
|
||||||
|
bool bAutoJoinSessionOnAcceptedUserInviteReceived = false;
|
||||||
|
|
||||||
// If true we will auto travel to a game session when an invite is received.
|
// If true we will auto travel to a game session when an invite is received.
|
||||||
// This can get in the way of Beacon Sessions, you may want to disable it.
|
// This can get in the way of Beacon Sessions, you may want to disable it.
|
||||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = AdvancedFriendsInterface)
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = AdvancedFriendsInterface)
|
||||||
bool bAutoTravelOnAcceptedUserInviteReceived = true;
|
bool bAutoTravelOnAcceptedUserInviteReceived = false;
|
||||||
|
|
||||||
//virtual void PostLoad() override;
|
//virtual void PostLoad() override;
|
||||||
virtual void Shutdown() override;
|
virtual void Shutdown() override;
|
||||||
|
|||||||
@@ -22,9 +22,15 @@ UAdvancedFriendsGameInstance::UAdvancedFriendsGameInstance(const FObjectInitiali
|
|||||||
|
|
||||||
void UAdvancedFriendsGameInstance::OnSessionUserInviteAccepted(const bool bWasSuccessful, const int32 ControllerId, FUniqueNetIdPtr UserId, const FOnlineSessionSearchResult& InviteResult)
|
void UAdvancedFriendsGameInstance::OnSessionUserInviteAccepted(const bool bWasSuccessful, const int32 ControllerId, FUniqueNetIdPtr UserId, const FOnlineSessionSearchResult& InviteResult)
|
||||||
{
|
{
|
||||||
|
if (!bAutoJoinSessionOnAcceptedUserInviteReceived)
|
||||||
|
return;
|
||||||
|
|
||||||
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(GetWorld());
|
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(GetWorld());
|
||||||
if (SessionInterface.IsValid())
|
if (SessionInterface.IsValid())
|
||||||
{
|
{
|
||||||
|
// Eventually call this?, would need another call back to run through
|
||||||
|
//SessionInterface->DestroySession(NAME_GameSession);
|
||||||
|
|
||||||
SessionInterface->ClearOnJoinSessionCompleteDelegate_Handle(OnJoinSessionCompleteDelegateHandle);
|
SessionInterface->ClearOnJoinSessionCompleteDelegate_Handle(OnJoinSessionCompleteDelegateHandle);
|
||||||
OnJoinSessionCompleteDelegateHandle = SessionInterface->AddOnJoinSessionCompleteDelegate_Handle(
|
OnJoinSessionCompleteDelegateHandle = SessionInterface->AddOnJoinSessionCompleteDelegate_Handle(
|
||||||
FOnJoinSessionCompleteDelegate::CreateUObject(this, &UAdvancedFriendsGameInstance::OnJoinSessionComplete));
|
FOnJoinSessionCompleteDelegate::CreateUObject(this, &UAdvancedFriendsGameInstance::OnJoinSessionComplete));
|
||||||
|
|||||||
@@ -151,7 +151,9 @@ void UAdvancedFriendsLibrary::GetFriend(APlayerController *PlayerController, con
|
|||||||
Friend.PresenceInfo.bIsPlaying = pres.bIsPlaying;
|
Friend.PresenceInfo.bIsPlaying = pres.bIsPlaying;
|
||||||
Friend.PresenceInfo.bIsPlayingThisGame = pres.bIsPlayingThisGame;
|
Friend.PresenceInfo.bIsPlayingThisGame = pres.bIsPlayingThisGame;
|
||||||
Friend.PresenceInfo.PresenceState = ((EBPOnlinePresenceState)((int32)pres.Status.State));
|
Friend.PresenceInfo.PresenceState = ((EBPOnlinePresenceState)((int32)pres.Status.State));
|
||||||
|
|
||||||
// #TODO: Check back in on this in shipping, epic is missing the UTF8_TO_TCHAR call on converting this and its making an invalid string
|
// #TODO: Check back in on this in shipping, epic is missing the UTF8_TO_TCHAR call on converting this and its making an invalid string
|
||||||
|
// OnlineFriendPresenceInterfaceSteam has the issue
|
||||||
//Friend.PresenceInfo.StatusString = pres.Status.StatusStr;
|
//Friend.PresenceInfo.StatusString = pres.Status.StatusStr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -266,6 +268,7 @@ void UAdvancedFriendsLibrary::GetStoredFriendsList(APlayerController *PlayerCont
|
|||||||
BPF.PresenceInfo.bIsPlaying = pres.bIsPlaying;
|
BPF.PresenceInfo.bIsPlaying = pres.bIsPlaying;
|
||||||
BPF.PresenceInfo.PresenceState = ((EBPOnlinePresenceState)((int32)pres.Status.State));
|
BPF.PresenceInfo.PresenceState = ((EBPOnlinePresenceState)((int32)pres.Status.State));
|
||||||
// #TODO: Check back in on this in shipping, epic is missing the UTF8_TO_TCHAR call on converting this and its making an invalid string
|
// #TODO: Check back in on this in shipping, epic is missing the UTF8_TO_TCHAR call on converting this and its making an invalid string
|
||||||
|
// OnlineFriendPresenceInterfaceSteam has the issue
|
||||||
//BPF.PresenceInfo.StatusString = pres.Status.StatusStr;
|
//BPF.PresenceInfo.StatusString = pres.Status.StatusStr;
|
||||||
BPF.PresenceInfo.bIsJoinable = pres.bIsJoinable;
|
BPF.PresenceInfo.bIsJoinable = pres.bIsJoinable;
|
||||||
BPF.PresenceInfo.bIsPlayingThisGame = pres.bIsPlayingThisGame;
|
BPF.PresenceInfo.bIsPlayingThisGame = pres.bIsPlayingThisGame;
|
||||||
|
|||||||
@@ -2,8 +2,8 @@
|
|||||||
"FileVersion" : 3,
|
"FileVersion" : 3,
|
||||||
|
|
||||||
"FriendlyName" : "Advanced Steam Sessions",
|
"FriendlyName" : "Advanced Steam Sessions",
|
||||||
"Version" : 5.4,
|
"Version" : 5.7,
|
||||||
"VersionName": "5.4",
|
"VersionName": "5.7",
|
||||||
"Description" : "Adds new blueprint functions to handle more advanced session operations in Steam. REQUIRES ADVANCED SESSIONS",
|
"Description" : "Adds new blueprint functions to handle more advanced session operations in Steam. REQUIRES ADVANCED SESSIONS",
|
||||||
"Category" : "Advanced Sessions Plugin",
|
"Category" : "Advanced Sessions Plugin",
|
||||||
"CreatedBy" : "Joshua Statzer",
|
"CreatedBy" : "Joshua Statzer",
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ MSVC_PRAGMA(warning(pop))
|
|||||||
#endif // USING_CODE_ANALYSIS
|
#endif // USING_CODE_ANALYSIS
|
||||||
|
|
||||||
#include <steam/isteamapps.h>
|
#include <steam/isteamapps.h>
|
||||||
#include <steam/isteamapplist.h>
|
//#include <steam/isteamapplist.h>
|
||||||
//#include <OnlineSubsystemSteamTypes.h>
|
//#include <OnlineSubsystemSteamTypes.h>
|
||||||
#pragma pop_macro("ARRAY_COUNT")
|
#pragma pop_macro("ARRAY_COUNT")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user