diff --git a/Source/RWTHVRCluster/Private/CAVEOverlay/CAVEOverlayController.cpp b/Source/RWTHVRCluster/Private/CAVEOverlay/CAVEOverlayController.cpp index dec8239cd778e9d40e0503e91fbfac3cbb7a99fc..ec52a1f987a193c228a88e091ab72548fc54db2c 100644 --- a/Source/RWTHVRCluster/Private/CAVEOverlay/CAVEOverlayController.cpp +++ b/Source/RWTHVRCluster/Private/CAVEOverlay/CAVEOverlayController.cpp @@ -156,7 +156,7 @@ void ACAVEOverlayController::BeginPlay() return; //Input config - if (UVirtualRealityUtilities::IsMaster()) + if (UVirtualRealityUtilities::IsPrimaryNode()) { if (CycleDoorTypeInputAction == nullptr || IMCCaveOverlayInputMapping == nullptr) { diff --git a/Source/RWTHVRCluster/Private/CaveSetup.cpp b/Source/RWTHVRCluster/Private/CaveSetup.cpp index 8691ab845938a94689260b8757afeb07256be6b1..debb2b14c4f49de450c60c9c393932bcff61d1b5 100644 --- a/Source/RWTHVRCluster/Private/CaveSetup.cpp +++ b/Source/RWTHVRCluster/Private/CaveSetup.cpp @@ -39,9 +39,9 @@ void ACaveSetup::BeginPlay() } } - // Apply the DTrack LiveLink Preset. Only do this if we are the master + // Apply the DTrack LiveLink Preset. Only do this if we are the primaryNode - if (UVirtualRealityUtilities::IsMaster()) + if (UVirtualRealityUtilities::IsPrimaryNode()) { if (LiveLinkPresetToApplyOnCave && LiveLinkPresetToApplyOnCave->IsValidLowLevelFast()) { diff --git a/Source/RWTHVRCluster/Public/Events/DisplayClusterEventParameterHelper.h b/Source/RWTHVRCluster/Public/Events/DisplayClusterEventParameterHelper.h index ef6d9891d62cd305027349d9ff5787adf79fe5c3..aa633d5fe15fe79c4462495363c4ffc3dbb2fcf6 100644 --- a/Source/RWTHVRCluster/Public/Events/DisplayClusterEventParameterHelper.h +++ b/Source/RWTHVRCluster/Public/Events/DisplayClusterEventParameterHelper.h @@ -2,12 +2,13 @@ #include "Serialization/MemoryReader.h" #include "Serialization/MemoryWriter.h" +#include "type_traits" template <typename ParameterType, typename... RemainingParameterTypes> inline void SerializeParameters(FMemoryWriter* MemoryWriter, ParameterType&& Parameter, RemainingParameterTypes&&... RemainingParameters) { - using NonConstType = typename TRemoveCV<typename TRemoveReference<ParameterType>::Type>::Type; + using NonConstType = typename std::remove_cv_t<typename TRemoveReference<ParameterType>::Type>; // const_cast because the same operator (<<) is used for reading and writing (*MemoryWriter) << const_cast<NonConstType&>(Parameter); SerializeParameters(MemoryWriter, Forward<RemainingParameterTypes>(RemainingParameters)...); @@ -44,7 +45,7 @@ inline RetType CallDelegateWithParameterMap( { // Create a tuple that holds all arguments. This assumes that all argument types are default constructible. However, all // types that overload the FArchive "<<" operator probably are. - TTuple<typename TRemoveCV<typename TRemoveReference<ArgTypes>::Type>::Type...> ArgumentTuple; + TTuple<typename std::remove_cv_t<typename TRemoveReference<ArgTypes>::Type>...> ArgumentTuple; // This call will parse the string map and fill all values in the tuple appropriately. FillArgumentTuple<0>(&ArgumentTuple, Parameters); diff --git a/Source/RWTHVRCluster/Public/Events/DisplayClusterEventWrapper.h b/Source/RWTHVRCluster/Public/Events/DisplayClusterEventWrapper.h index 8810c2a8df2cdb94fc6c76004a1e7fb55e0e8862..ef39e5ed0c21f99774ee2d36aae6f0dd5b8d10cc 100644 --- a/Source/RWTHVRCluster/Public/Events/DisplayClusterEventWrapper.h +++ b/Source/RWTHVRCluster/Public/Events/DisplayClusterEventWrapper.h @@ -5,7 +5,6 @@ #include "Cluster/DisplayClusterClusterEvent.h" #include "DisplayClusterEventParameterHelper.h" #include "Templates/IsInvocable.h" -#include "Templates/RemoveCV.h" static constexpr int32 CLUSTER_EVENT_WRAPPER_EVENT_ID = 1337420; @@ -69,7 +68,7 @@ public: // Create a tuple that holds all arguments. This assumes that all // argument types are default constructible. However, all // types that overload the FArchive "<<" operator probably are. - TTuple<typename TRemoveCV<typename TRemoveReference<ArgTypes>::Type>::Type...> ArgumentTuple; + TTuple<typename std::remove_cv_t<typename TRemoveReference<ArgTypes>::Type>...> ArgumentTuple; // This call will deserialze the values and fill all values in the tuple appropriately. FillArgumentTuple<0>(&MemoryReader, &ArgumentTuple); diff --git a/Source/RWTHVRToolkit/Private/Pawn/VirtualRealityPawn.cpp b/Source/RWTHVRToolkit/Private/Pawn/VirtualRealityPawn.cpp index 26e599357e557abc6263e0766b0adba5520ef1ec..a241f53678887fa98df8f4d71400e1b6a4cf2871 100644 --- a/Source/RWTHVRToolkit/Private/Pawn/VirtualRealityPawn.cpp +++ b/Source/RWTHVRToolkit/Private/Pawn/VirtualRealityPawn.cpp @@ -69,9 +69,9 @@ void AVirtualRealityPawn::NotifyControllerChanged() // Only do this for all local controlled pawns if (IsLocallyControlled()) { - // Only do this for the master or when we're running in standalone - if (UVirtualRealityUtilities::IsRoomMountedMode() && (UVirtualRealityUtilities::IsMaster() || GetNetMode()) == - NM_Standalone) + // Only do this for the primary node or when we're running in standalone + if (UVirtualRealityUtilities::IsRoomMountedMode() && (UVirtualRealityUtilities::IsPrimaryNode() || GetNetMode()) + == NM_Standalone) { // If we are also the authority (standalone or listen server), directly attach it to us. // If we are not (client), ask the server to do it. diff --git a/Source/RWTHVRToolkit/Private/Utility/VirtualRealityUtilities.cpp b/Source/RWTHVRToolkit/Private/Utility/VirtualRealityUtilities.cpp index 5653faff3662a212542df88aa979b938bbbfa5fe..c13df15f27d780d04bc8eee121c33068f1ba1dff 100644 --- a/Source/RWTHVRToolkit/Private/Utility/VirtualRealityUtilities.cpp +++ b/Source/RWTHVRToolkit/Private/Utility/VirtualRealityUtilities.cpp @@ -81,8 +81,8 @@ bool UVirtualRealityUtilities::IsRolv() #endif } -/* Return true on the Master in cluster mode and in a normal desktop session. Otherwise false */ -bool UVirtualRealityUtilities::IsMaster() +/* Return true on the Primary in cluster mode and in a normal desktop session. Otherwise false */ +bool UVirtualRealityUtilities::IsPrimaryNode() { #if PLATFORM_SUPPORTS_NDISPLAY if (!IDisplayCluster::IsAvailable()) @@ -92,7 +92,7 @@ bool UVirtualRealityUtilities::IsMaster() IDisplayClusterClusterManager* Manager = IDisplayCluster::Get().GetClusterMgr(); if (Manager == nullptr) { - return true; // if we are not in cluster mode, we are always the master + return true; // if we are not in cluster mode, we are always the primary node } return Manager->IsPrimary() || !Manager->IsSecondary(); #else @@ -100,9 +100,9 @@ bool UVirtualRealityUtilities::IsMaster() #endif } -bool UVirtualRealityUtilities::IsSlave() +bool UVirtualRealityUtilities::IsSecondaryNode() { - return !IsMaster(); + return !IsPrimaryNode(); } FString UVirtualRealityUtilities::GetNodeName() diff --git a/Source/RWTHVRToolkit/Public/Pawn/Navigation/VRPawnMovement.h b/Source/RWTHVRToolkit/Public/Pawn/Navigation/VRPawnMovement.h index 95e88e0d91ac56a5fe269f74abbaf70404660870..5f51243557066ddb24ed5d0b74de451487164fe0 100644 --- a/Source/RWTHVRToolkit/Public/Pawn/Navigation/VRPawnMovement.h +++ b/Source/RWTHVRToolkit/Public/Pawn/Navigation/VRPawnMovement.h @@ -75,7 +75,7 @@ private: UPROPERTY(VisibleAnywhere) UCapsuleComponent* CapsuleColliderComponent = nullptr; - UPROPERTY() + UPROPERTY(VisibleAnywhere, Transient, DuplicateTransient) USceneComponent* HeadComponent = nullptr; float VerticalSpeed = 0.0f; @@ -83,6 +83,6 @@ private: FVector LastSteeringCollisionVector; //just stored for performance gains; - UPROPERTY() + UPROPERTY(VisibleAnywhere, Transient, DuplicateTransient) TArray<AActor*> ActorsToIgnore; }; diff --git a/Source/RWTHVRToolkit/Public/Utility/VirtualRealityUtilities.h b/Source/RWTHVRToolkit/Public/Utility/VirtualRealityUtilities.h index d5ff0913274d21b0891a34c3d5b58d7019d6d31c..f2dbdcb1c3bc0885fec76920f9f61c5324a051a5 100644 --- a/Source/RWTHVRToolkit/Public/Utility/VirtualRealityUtilities.h +++ b/Source/RWTHVRToolkit/Public/Utility/VirtualRealityUtilities.h @@ -63,9 +63,9 @@ public: static bool IsRolv(); UFUNCTION(BlueprintPure, Category = "DisplayCluster") - static bool IsMaster(); + static bool IsPrimaryNode(); UFUNCTION(BlueprintPure, Category = "DisplayCluster") - static bool IsSlave(); + static bool IsSecondaryNode(); UFUNCTION(BlueprintPure, Category = "DisplayCluster") static FString GetNodeName();