mirror of
https://github.com/mordentral/AdvancedSessionsPlugin.git
synced 2025-10-23 08:24:18 +00:00
fixed deprecating function call
Former-commit-id: 3b0a2802808bce6cf442f233e5f041d8b0ea3505
This commit is contained in:
@@ -26,7 +26,7 @@ void UAdvancedSessionsLibrary::GetSessionID_AsString(const FBlueprintSessionResu
|
|||||||
|
|
||||||
void UAdvancedSessionsLibrary::GetCurrentSessionID_AsString(UObject* WorldContextObject, FString& SessionID)
|
void UAdvancedSessionsLibrary::GetCurrentSessionID_AsString(UObject* WorldContextObject, FString& SessionID)
|
||||||
{
|
{
|
||||||
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject);
|
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject, EGetWorldErrorMode::LogAndReturnNull);
|
||||||
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
||||||
|
|
||||||
if (!SessionInterface.IsValid())
|
if (!SessionInterface.IsValid())
|
||||||
@@ -128,7 +128,7 @@ void UAdvancedSessionsLibrary::GetExtraSettings(FBlueprintSessionResult SessionR
|
|||||||
|
|
||||||
void UAdvancedSessionsLibrary::GetSessionState(UObject* WorldContextObject, EBPOnlineSessionState &SessionState)
|
void UAdvancedSessionsLibrary::GetSessionState(UObject* WorldContextObject, EBPOnlineSessionState &SessionState)
|
||||||
{
|
{
|
||||||
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject);
|
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject, EGetWorldErrorMode::LogAndReturnNull);
|
||||||
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
||||||
|
|
||||||
if (!SessionInterface.IsValid())
|
if (!SessionInterface.IsValid())
|
||||||
@@ -142,7 +142,7 @@ void UAdvancedSessionsLibrary::GetSessionState(UObject* WorldContextObject, EBPO
|
|||||||
|
|
||||||
void UAdvancedSessionsLibrary::GetSessionSettings(UObject* WorldContextObject, int32 &NumConnections, int32 &NumPrivateConnections, bool &bIsLAN, bool &bIsDedicated, bool &bAllowInvites, bool &bAllowJoinInProgress, bool &bIsAnticheatEnabled, int32 &BuildUniqueID, TArray<FSessionPropertyKeyPair> &ExtraSettings, EBlueprintResultSwitch &Result)
|
void UAdvancedSessionsLibrary::GetSessionSettings(UObject* WorldContextObject, int32 &NumConnections, int32 &NumPrivateConnections, bool &bIsLAN, bool &bIsDedicated, bool &bAllowInvites, bool &bAllowJoinInProgress, bool &bIsAnticheatEnabled, int32 &BuildUniqueID, TArray<FSessionPropertyKeyPair> &ExtraSettings, EBlueprintResultSwitch &Result)
|
||||||
{
|
{
|
||||||
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject);
|
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject, EGetWorldErrorMode::LogAndReturnNull);
|
||||||
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
||||||
|
|
||||||
if (!SessionInterface.IsValid())
|
if (!SessionInterface.IsValid())
|
||||||
@@ -183,7 +183,7 @@ void UAdvancedSessionsLibrary::GetSessionSettings(UObject* WorldContextObject, i
|
|||||||
|
|
||||||
void UAdvancedSessionsLibrary::IsPlayerInSession(UObject* WorldContextObject, const FBPUniqueNetId &PlayerToCheck, bool &bIsInSession)
|
void UAdvancedSessionsLibrary::IsPlayerInSession(UObject* WorldContextObject, const FBPUniqueNetId &PlayerToCheck, bool &bIsInSession)
|
||||||
{
|
{
|
||||||
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject);
|
UWorld* const World = GEngine->GetWorldFromContextObject(WorldContextObject, EGetWorldErrorMode::LogAndReturnNull);
|
||||||
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
IOnlineSessionPtr SessionInterface = Online::GetSessionInterface(World);
|
||||||
|
|
||||||
if (!SessionInterface.IsValid())
|
if (!SessionInterface.IsValid())
|
||||||
|
Reference in New Issue
Block a user