void FOnlineSubsystemSteamModule::LoadSteamModules() { UE_LOG_ONLINE(Display, TEXT("Loading Steam SDK %s"), STEAM_SDK_VER); #if PLATFORM_WINDOWS #if PLATFORM_64BITS FString RootSteamPath = GetSteamModulePath(); FPlatformProcess::PushDllDirectory(*RootSteamPath); SteamDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steam_api64.dll")); #if 0 //64 bit not supported well at present, use Steam Client dlls // Load the Steam dedicated server dlls (assumes no Steam Client running) if (IsRunningDedicatedServer()) { SteamServerDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steamclient64.dll")); } #endif FPlatformProcess::PopDllDirectory(*RootSteamPath); #else //PLATFORM_64BITS FString RootSteamPath = GetSteamModulePath(); FPlatformProcess::PushDllDirectory(*RootSteamPath); SteamDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steam_api.dll")); if (IsRunningDedicatedServer()) { SteamServerDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steamclient.dll")); } FPlatformProcess::PopDllDirectory(*RootSteamPath); #endif //PLATFORM_64BITS #elif PLATFORM_MAC SteamDLLHandle = FPlatformProcess::GetDllHandle(TEXT("libsteam_api.dylib")); #endif //PLATFORM_WINDOWS }
void FOnlineSubsystemSteamModule::LoadSteamModules() { UE_LOG_ONLINE(Display, TEXT("Loading Steam SDK %s"), STEAM_SDK_VER); #if PLATFORM_WINDOWS #if PLATFORM_64BITS FString RootSteamPath = GetSteamModulePath(); FPlatformProcess::PushDllDirectory(*RootSteamPath); SteamDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steam_api64.dll")); #if 0 //64 bit not supported well at present, use Steam Client dlls // [RCL] 2015-02-09 the above comment ("64 bit not supported well...") is from (early) 2012, things might have changed // Load the Steam dedicated server dlls (assumes no Steam Client running) if (IsRunningDedicatedServer()) { SteamServerDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steamclient64.dll")); } #endif FPlatformProcess::PopDllDirectory(*RootSteamPath); #else //PLATFORM_64BITS FString RootSteamPath = GetSteamModulePath(); FPlatformProcess::PushDllDirectory(*RootSteamPath); SteamDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steam_api.dll")); if (IsRunningDedicatedServer()) { SteamServerDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "steamclient.dll")); } FPlatformProcess::PopDllDirectory(*RootSteamPath); #endif //PLATFORM_64BITS #elif PLATFORM_MAC SteamDLLHandle = FPlatformProcess::GetDllHandle(TEXT("libsteam_api.dylib")); #elif PLATFORM_LINUX #if LOADING_STEAM_LIBRARIES_DYNAMICALLY UE_LOG_ONLINE(Log, TEXT("Loading system libsteam_api.so.")); SteamDLLHandle = FPlatformProcess::GetDllHandle(TEXT("libsteam_api.so")); if (SteamDLLHandle == nullptr) { // try bundled one UE_LOG_ONLINE(Log, TEXT("Could not find system one, loading bundled libsteam_api.so.")); FString RootSteamPath = FPaths::EngineDir() / FString::Printf(TEXT("Binaries/ThirdParty/Steamworks/%s/Linux/"), STEAM_SDK_VER); SteamDLLHandle = FPlatformProcess::GetDllHandle(*(RootSteamPath + "libsteam_api.so")); } #else UE_LOG_ONLINE(Log, TEXT("libsteam_api.so is linked explicitly and should be already loaded.")); #endif // LOADING_STEAM_LIBRARIES_DYNAMICALLY #endif //PLATFORM_WINDOWS }
void USoundWave::PostLoad() { Super::PostLoad(); if (GetOutermost()->HasAnyPackageFlags(PKG_ReloadingForCooker)) { return; } // Compress to whatever formats the active target platforms want // static here as an optimization ITargetPlatformManagerModule* TPM = GetTargetPlatformManager(); if (TPM) { const TArray<ITargetPlatform*>& Platforms = TPM->GetActiveTargetPlatforms(); for (int32 Index = 0; Index < Platforms.Num(); Index++) { GetCompressedData(Platforms[Index]->GetWaveFormat(this)); } } // We don't precache default objects and we don't precache in the Editor as the latter will // most likely cause us to run out of memory. if (!GIsEditor && !IsTemplate( RF_ClassDefaultObject ) && GEngine) { FAudioDevice* AudioDevice = GEngine->GetMainAudioDevice(); if (AudioDevice && AudioDevice->AreStartupSoundsPreCached()) { // Upload the data to the hardware, but only if we've precached startup sounds already AudioDevice->Precache(this); } // remove bulk data if no AudioDevice is used and no sounds were initialized else if(IsRunningGame()) { RawData.RemoveBulkData(); } } // Only add this streaming sound if we're not a dedicated server or if there is an audio device manager if (IsStreaming() && !IsRunningDedicatedServer() && GEngine && GEngine->GetAudioDeviceManager()) { #if WITH_EDITORONLY_DATA FinishCachePlatformData(); #endif // #if WITH_EDITORONLY_DATA IStreamingManager::Get().GetAudioStreamingManager().AddStreamingSoundWave(this); } #if WITH_EDITORONLY_DATA if (!SourceFilePath_DEPRECATED.IsEmpty() && AssetImportData) { FAssetImportInfo Info; Info.Insert(FAssetImportInfo::FSourceFile(SourceFilePath_DEPRECATED)); AssetImportData->SourceData = MoveTemp(Info); } #endif // #if WITH_EDITORONLY_DATA INC_FLOAT_STAT_BY( STAT_AudioBufferTime, Duration ); INC_FLOAT_STAT_BY( STAT_AudioBufferTimeChannels, NumChannels * Duration ); }
void USkeletalMeshComponent::PostPhysicsTick(FPrimitiveComponentPostPhysicsTickFunction &ThisTickFunction) { Super::PostPhysicsTick(ThisTickFunction); // if physics is disabled on dedicated server, no reason to be here. if ( !bEnablePhysicsOnDedicatedServer && IsRunningDedicatedServer() ) { return; } if (IsRegistered() && IsSimulatingPhysics()) { SyncComponentToRBPhysics(); } // this used to not run if not rendered, but that causes issues such as bounds not updated // causing it to not rendered, at the end, I think we should blend body positions // for example if you're only simulating, this has to happen all the time // whether looking at it or not, otherwise // @todo better solution is to check if it has moved by changing SyncComponentToRBPhysics to return true if anything modified // and run this if that is true or rendered // that will at least reduce the chance of mismatch // generally if you move your actor position, this has to happen to approximately match their bounds if( Bodies.Num() > 0 && IsRegistered() ) { BlendInPhysics(); } }
bool FOnlineIdentitySteam::AutoLogin(int32 LocalUserNum) { if (!IsRunningDedicatedServer()) { // Double check they are properly logged in if (SteamUserPtr != NULL && // Login is handled by steam SteamUserPtr->BLoggedOn()) { // Login changed delegate TriggerOnLoginChangedDelegates(LocalUserNum); // Login completion delegate FString AuthToken = GetAuthToken(LocalUserNum); TriggerOnLoginCompleteDelegates(LocalUserNum, true, FUniqueNetIdSteam(SteamUserPtr->GetSteamID()), TEXT("")); return true; } TriggerOnLoginCompleteDelegates(0, false, FUniqueNetIdSteam(0), TEXT("AutoLogin failed. Not logged in or no connection.")); return false; } else { // Autologin for dedicated servers happens via session creation in the GameServerAPI LogOnAnonymous() return false; } }
void FEmotionDetector::OnWorldDestroyed(UWorld* World) { if (IsRunningCommandlet() || IsRunningDedicatedServer()) { return; } }
USpinBox::USpinBox(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { if (!IsRunningDedicatedServer()) { static ConstructorHelpers::FObjectFinder<UFont> RobotoFontObj(TEXT("/Engine/EngineFonts/Roboto")); Font = FSlateFontInfo(RobotoFontObj.Object, 12, FName("Bold")); } // Grab other defaults from slate arguments. SSpinBox<float>::FArguments Defaults; Value = Defaults._Value.Get(); MinValue = Defaults._MinValue.Get().Get(0.0f); MaxValue = Defaults._MaxValue.Get().Get(0.0f); MinSliderValue = Defaults._MinSliderValue.Get().Get(0.0f); MaxSliderValue = Defaults._MaxSliderValue.Get().Get(0.0f); Delta = Defaults._Delta.Get(); SliderExponent = Defaults._SliderExponent.Get(); MinDesiredWidth = Defaults._MinDesiredWidth.Get(); ClearKeyboardFocusOnCommit = Defaults._ClearKeyboardFocusOnCommit.Get(); SelectAllTextOnCommit = Defaults._SelectAllTextOnCommit.Get(); WidgetStyle = *Defaults._Style; ForegroundColor = FSlateColor(FLinearColor::Black); }
FByteBulkData* USoundWave::GetCompressedData(FName Format) { if (IsTemplate() || IsRunningDedicatedServer()) { return NULL; } bool bContainedData = CompressedFormatData.Contains(Format); FByteBulkData* Result = &CompressedFormatData.GetFormat(Format); if (!bContainedData) { if (!FPlatformProperties::RequiresCookedData() && GetDerivedDataCache()) { TArray<uint8> OutData; FDerivedAudioDataCompressor* DeriveAudioData = new FDerivedAudioDataCompressor(this, Format); GetDerivedDataCacheRef().GetSynchronous(DeriveAudioData, OutData); if (OutData.Num()) { Result->Lock(LOCK_READ_WRITE); FMemory::Memcpy(Result->Realloc(OutData.Num()), OutData.GetData(), OutData.Num()); Result->Unlock(); } } else { UE_LOG(LogAudio, Error, TEXT("Attempt to access the DDC when there is none available on sound '%s', format = %s. Should have been cooked."), *GetFullName(), *Format.ToString()); } } check(Result); return Result->GetBulkDataSize() > 0 ? Result : NULL; // we don't return empty bulk data...but we save it to avoid thrashing the DDC }
UEditableTextBox::UEditableTextBox(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { ForegroundColor_DEPRECATED = FLinearColor::Black; BackgroundColor_DEPRECATED = FLinearColor::White; ReadOnlyForegroundColor_DEPRECATED = FLinearColor::Black; if (!IsRunningDedicatedServer()) { static ConstructorHelpers::FObjectFinder<UFont> RobotoFontObj(TEXT("/Engine/EngineFonts/Roboto")); Font_DEPRECATED = FSlateFontInfo(RobotoFontObj.Object, 12, FName("Bold")); } // Grab other defaults from slate arguments. SEditableTextBox::FArguments Defaults; IsReadOnly = Defaults._IsReadOnly.Get(); IsPassword = Defaults._IsPassword.Get(); MinimumDesiredWidth = Defaults._MinDesiredWidth.Get(); Padding_DEPRECATED = Defaults._Padding.Get(); IsCaretMovedWhenGainFocus = Defaults._IsCaretMovedWhenGainFocus.Get(); SelectAllTextWhenFocused = Defaults._SelectAllTextWhenFocused.Get(); RevertTextOnEscape = Defaults._RevertTextOnEscape.Get(); ClearKeyboardFocusOnCommit = Defaults._ClearKeyboardFocusOnCommit.Get(); SelectAllTextOnCommit = Defaults._SelectAllTextOnCommit.Get(); AllowContextMenu = Defaults._AllowContextMenu.Get(); WidgetStyle = *Defaults._Style; }
void FEmotionDetector::OnWorldCreated(UWorld* World, const UWorld::InitializationValues IVS) { if (IsRunningCommandlet() || IsRunningDedicatedServer()) { return; } }
const FString& UGameMapsSettings::GetGlobalDefaultGameMode( ) { UGameMapsSettings* GameMapsSettings = Cast<UGameMapsSettings>(UGameMapsSettings::StaticClass()->GetDefaultObject()); return IsRunningDedicatedServer() && GameMapsSettings->GlobalDefaultServerGameMode.IsValid() ? GameMapsSettings->GlobalDefaultServerGameMode.ToString() : GameMapsSettings->GlobalDefaultGameMode.ToString(); }
/** * Return true if we should lag the async scene a frame **/ FORCEINLINE static bool FrameLagAsync() { if (IsRunningDedicatedServer()) { return false; } return true; }
/** * Return true if we should be running in single threaded mode, ala dedicated server **/ FORCEINLINE static bool PhysSingleThreadedMode() { if (IsRunningDedicatedServer() || FPlatformMisc::NumberOfCores() < 3 || !FPlatformProcess::SupportsMultithreading()) { return true; } return false; }
float UGameEngine::GetMaxTickRate(float DeltaTime, bool bAllowFrameRateSmoothing) const { float MaxTickRate = 0.f; if (FPlatformProperties::SupportsWindowedMode() == false && !IsRunningDedicatedServer()) { static const auto CVar = IConsoleManager::Get().FindTConsoleVariableDataInt(TEXT("r.VSync")); // Limit framerate on console if VSYNC is enabled to avoid jumps from 30 to 60 and back. if( CVar->GetValueOnGameThread() != 0 ) { if (SmoothedFrameRateRange.HasUpperBound()) { MaxTickRate = SmoothedFrameRateRange.GetUpperBoundValue(); } } } else { UWorld* World = NULL; for (int32 WorldIndex = 0; WorldIndex < WorldList.Num(); ++WorldIndex) { if (WorldList[WorldIndex].WorldType == EWorldType::Game) { World = WorldList[WorldIndex].World(); break; } } if( World ) { UNetDriver* NetDriver = World->GetNetDriver(); // In network games, limit framerate to not saturate bandwidth. if( NetDriver && (NetDriver->GetNetMode() == NM_DedicatedServer || (NetDriver->GetNetMode() == NM_ListenServer && NetDriver->bClampListenServerTickRate))) { // We're a dedicated server, use the LAN or Net tick rate. MaxTickRate = FMath::Clamp( NetDriver->NetServerMaxTickRate, 10, 120 ); } /*else if( NetDriver && NetDriver->ServerConnection ) { if( NetDriver->ServerConnection->CurrentNetSpeed <= 10000 ) { MaxTickRate = FMath::Clamp( MaxTickRate, 10.f, 90.f ); } }*/ } } // See if the code in the base class wants to replace this float SuperTickRate = Super::GetMaxTickRate(DeltaTime, bAllowFrameRateSmoothing); if(SuperTickRate != 0.0) { MaxTickRate = SuperTickRate; } return MaxTickRate; }
void FSignificanceManagerModule::StartupModule() { FWorldDelegates::OnPreWorldInitialization.AddStatic(&FSignificanceManagerModule::OnWorldInit); FWorldDelegates::OnWorldCleanup.AddStatic(&FSignificanceManagerModule::OnWorldCleanup); if (!IsRunningDedicatedServer()) { AHUD::OnShowDebugInfo.AddStatic(&FSignificanceManagerModule::OnShowDebugInfo); } }
bool USoundWave::HasCompressedData(FName Format) const { if (IsTemplate() || IsRunningDedicatedServer()) { return false; } return CompressedFormatData.Contains(Format); }
void FWebMRecord::OnWorldDestroyed(UWorld* World) { if (IsRunningCommandlet() || IsRunningDedicatedServer()) { return; } // Might want to track if the world we're recording just got destroyed, but really doesn't stop this train }
bool IsDedicatedServerForGameplayCue() { #if WITH_EDITOR // This will handle dedicated server PIE case properly return GEngine->ShouldAbsorbCosmeticOnlyEvent(); #else // When in standalone non editor, this is the fastest way to check return IsRunningDedicatedServer(); #endif }
UTextRenderComponent::UTextRenderComponent(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { if( !IsRunningDedicatedServer() ) { // Structure to hold one-time initialization struct FConstructorStatics { ConstructorHelpers::FObjectFinderOptional<UFont> Font; ConstructorHelpers::FObjectFinderOptional<UMaterial> TextMaterial; FConstructorStatics() : Font(TEXT("/Engine/EngineFonts/RobotoDistanceField")) , TextMaterial(TEXT("/Engine/EngineMaterials/DefaultTextMaterialOpaque")) { } }; static FConstructorStatics ConstructorStatics; { // Static used to watch for culture changes and update all live UTextRenderComponent components // In this constructor so that it has a known initialization order, and is only created when we need it static FTextRenderComponentCultureChangedFixUp TextRenderComponentCultureChangedFixUp; } PrimaryComponentTick.bCanEverTick = false; bTickInEditor = false; Text = LOCTEXT("DefaultText", "Text"); Font = ConstructorStatics.Font.Get(); TextMaterial = ConstructorStatics.TextMaterial.Get(); SetCollisionProfileName(UCollisionProfile::NoCollision_ProfileName); TextRenderColor = FColor::White; XScale = 1; YScale = 1; HorizSpacingAdjust = 0; HorizontalAlignment = EHTA_Left; VerticalAlignment = EVRTA_TextBottom; bGenerateOverlapEvents = false; if(Font) { Font->ConditionalPostLoad(); WorldSize = Font->GetMaxCharHeight(); InvDefaultSize = 1.0f / WorldSize; } else { WorldSize = 30.0f; InvDefaultSize = 1.0f / 30.0f; } } }
FEngineFontServices::FEngineFontServices() { check(IsInGameThread()); #if !UE_SERVER if (!IsRunningDedicatedServer() && !IsRunningCommandlet()) { SlateFontServices = FSlateApplication::Get().GetRenderer()->GetFontServices(); } #endif }
FWidgetRenderer::FWidgetRenderer(bool bUseGammaCorrection) : bPrepassNeeded(true) , bUseGammaSpace(bUseGammaCorrection) { #if !UE_SERVER if (!IsRunningDedicatedServer()) { Renderer = FModuleManager::Get().LoadModuleChecked<ISlateRHIRendererModule>("SlateRHIRenderer").CreateSlate3DRenderer(bUseGammaSpace); } #endif }
bool IsServerForOnlineSubsystems(FName WorldContextHandle) { if (GIsServerDelegate.IsBound()) { return GIsServerDelegate.Execute(WorldContextHandle); } else { return IsRunningDedicatedServer(); } }
URichTextBlock::URichTextBlock(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { if (!IsRunningDedicatedServer()) { static ConstructorHelpers::FObjectFinder<UFont> RobotoFontObj(TEXT("/Engine/EngineFonts/Roboto")); Font = FSlateFontInfo(RobotoFontObj.Object, 12, FName("Regular")); } Color = FLinearColor::White; Decorators.Add(ObjectInitializer.CreateOptionalDefaultSubobject<URichTextBlockDecorator>(this, FName("DefaultDecorator"))); }
void UGameEngine::LoadRuntimeEngineStartupModules() { // NOTE: These modules will be loaded when the game starts up, and also when the editor starts up. // We only want live streaming support if we're actually in a game if( !IsRunningDedicatedServer() && !IsRunningCommandlet() ) { FModuleManager::Get().LoadModule( TEXT("GameLiveStreaming") ); } // ... load other required engine runtime modules here (but NOT editor modules) ... }
bool UAmethystGameInstance::Tick(float DeltaSeconds) { // Dedicated server doesn't need to worry about game state if (IsRunningDedicatedServer() == true) { return true; } MaybeChangeState(); UAmethystGameViewportClient * AmethystViewport = Cast<UAmethystGameViewportClient>(GetGameViewportClient()); if (CurrentState != AmethystGameInstanceState::WelcomeScreen) { // If at any point we aren't licensed (but we are after welcome screen) bounce them back to the welcome screen if (!bIsLicensed && CurrentState != AmethystGameInstanceState::None && !AmethystViewport->IsShowingDialog()) { const FText ReturnReason = NSLOCTEXT("ProfileMessages", "NeedLicense", "The signed in users do not have a license for this game. Please purchase AmethystGame from the Xbox Marketplace or sign in a user with a valid license."); const FText OKButton = NSLOCTEXT("DialogButtons", "OKAY", "OK"); ShowMessageThenGotoState(ReturnReason, OKButton, FText::GetEmpty(), AmethystGameInstanceState::WelcomeScreen); } // Show controller disconnected dialog if any local players have an invalid controller if (AmethystViewport != NULL && !AmethystViewport->IsShowingDialog()) { for (int i = 0; i < LocalPlayers.Num(); ++i) { if (LocalPlayers[i] && LocalPlayers[i]->GetControllerId() == -1) { AmethystViewport->ShowDialog( LocalPlayers[i], EAmethystDialogType::ControllerDisconnected, FText::Format(NSLOCTEXT("ProfileMessages", "PlayerReconnectControllerFmt", "Player {0}, please reconnect your controller."), FText::AsNumber(i + 1)), #ifdef PLATFORM_PS4 NSLOCTEXT("DialogButtons", "PS4_CrossButtonContinue", "Cross Button - Continue"), #else NSLOCTEXT("DialogButtons", "AButtonContinue", "A - Continue"), #endif FText::GetEmpty(), FOnClicked::CreateUObject(this, &UAmethystGameInstance::OnControllerReconnectConfirm), FOnClicked() ); } } } } return true; }
UTextureRenderTarget2D* FWidgetRenderer::DrawWidget(const TSharedRef<SWidget>& Widget, FVector2D DrawSize) { if ( !IsRunningDedicatedServer() ) { UTextureRenderTarget2D* RenderTarget = FWidgetRenderer::CreateTargetFor(DrawSize, TF_Bilinear, bUseGammaSpace); DrawWidget(RenderTarget, Widget, DrawSize, 0); return RenderTarget; } return nullptr; }
void UGameMapsSettings::SetGameDefaultMap( const FString& NewMap ) { UGameMapsSettings* GameMapsSettings = Cast<UGameMapsSettings>(UGameMapsSettings::StaticClass()->GetDefaultObject()); if (IsRunningDedicatedServer()) { GameMapsSettings->ServerDefaultMap = NewMap; } else { GameMapsSettings->GameDefaultMap = NewMap; } }
bool FOnlineVoiceImpl::Init() { bool bSuccess = false; if (!GConfig->GetInt(TEXT("OnlineSubsystem"),TEXT("MaxLocalTalkers"), MaxLocalTalkers, GEngineIni)) { MaxLocalTalkers = MAX_SPLITSCREEN_TALKERS; UE_LOG(LogVoice, Warning, TEXT("Missing MaxLocalTalkers key in OnlineSubsystem of DefaultEngine.ini")); } if (!GConfig->GetInt(TEXT("OnlineSubsystem"),TEXT("MaxRemoteTalkers"), MaxRemoteTalkers, GEngineIni)) { MaxRemoteTalkers = MAX_REMOTE_TALKERS; UE_LOG(LogVoice, Warning, TEXT("Missing MaxRemoteTalkers key in OnlineSubsystem of DefaultEngine.ini")); } if (!GConfig->GetFloat(TEXT("OnlineSubsystem"),TEXT("VoiceNotificationDelta"), VoiceNotificationDelta, GEngineIni)) { VoiceNotificationDelta = 0.2; UE_LOG(LogVoice, Warning, TEXT("Missing VoiceNotificationDelta key in OnlineSubsystem of DefaultEngine.ini")); } if (OnlineSubsystem) { SessionInt = OnlineSubsystem->GetSessionInterface().Get(); IdentityInt = OnlineSubsystem->GetIdentityInterface().Get(); bSuccess = SessionInt && IdentityInt; } if (bSuccess && !IsRunningDedicatedServer()) { VoiceEngine = new FVoiceEngineImpl(OnlineSubsystem); bSuccess = VoiceEngine->Init(MaxLocalTalkers, MaxRemoteTalkers); LocalTalkers.Init(FLocalTalker(), MaxLocalTalkers); } RemoteTalkers.Empty(MaxRemoteTalkers); if (!bSuccess) { LocalTalkers.Empty(); RemoteTalkers.Empty(); delete VoiceEngine; VoiceEngine = NULL; UE_LOG(LogVoice, Warning, TEXT("Failed to initialize voice interface")); } return bSuccess; }
bool FOnlineSubsystemSteamModule::AreSteamDllsLoaded() const { bool bLoadedClientDll = true; bool bLoadedServerDll = true; #if LOADING_STEAM_LIBRARIES_DYNAMICALLY bLoadedClientDll = (SteamDLLHandle != NULL) ? true : false; #if LOADING_STEAM_SERVER_LIBRARY_DYNAMICALLY bLoadedServerDll = IsRunningDedicatedServer() ? ((SteamServerDLLHandle != NULL) ? true : false) : true; #endif //LOADING_STEAM_SERVER_LIBRARY_DYNAMICALLY #endif // LOADING_STEAM_LIBRARIES_DYNAMICALLY return bLoadedClientDll && bLoadedServerDll; }
bool FOnlineSubsystemSteamModule::AreSteamDllsLoaded() const { bool bLoadedClientDll = true; bool bLoadedServerDll = true; #if PLATFORM_WINDOWS || PLATFORM_MAC bLoadedClientDll = (SteamDLLHandle != NULL) ? true : false; #if PLATFORM_32BITS bLoadedServerDll = IsRunningDedicatedServer() ? ((SteamServerDLLHandle != NULL) ? true : false) : true; #endif //PLATFORM_32BITS #endif //PLATFORM_WINDOWS || PLATFORM_MAC return bLoadedClientDll && bLoadedServerDll; }