diff --git a/Source/UnrealLibretro/Private/LibretroBlueprintFunctionLibrary.cpp b/Source/UnrealLibretro/Private/LibretroBlueprintFunctionLibrary.cpp index 13c2fdf..6d88962 100644 --- a/Source/UnrealLibretro/Private/LibretroBlueprintFunctionLibrary.cpp +++ b/Source/UnrealLibretro/Private/LibretroBlueprintFunctionLibrary.cpp @@ -1,11 +1,16 @@ #include "LibretroBlueprintFunctionLibrary.h" +#include "Runtime/Launch/Resources/Version.h" #include "GameFramework/Actor.h" #include "Engine/Engine.h" +#include "Engine/EngineTypes.h" +#if ENGINE_MAJOR_VERSION == 5 \ + && ENGINE_MINOR_VERSION >= 4 +#include "Engine/HitResult.h" +#endif #include "Camera/CameraComponent.h" #include "PhysicsEngine/PhysicsSettings.h" -#include "Runtime/Launch/Resources/Version.h" #if ENGINE_MAJOR_VERSION != 5 \ || ENGINE_MINOR_VERSION < 1 diff --git a/Source/UnrealLibretro/Private/LibretroContext.cpp b/Source/UnrealLibretro/Private/LibretroContext.cpp index 6fd37ec..99fdecf 100644 --- a/Source/UnrealLibretro/Private/LibretroContext.cpp +++ b/Source/UnrealLibretro/Private/LibretroContext.cpp @@ -1,4 +1,3 @@ - #include "LibretroContext.h" extern "C" { @@ -16,6 +15,8 @@ extern "C" #include "HAL/FileManager.h" #include "Misc/Paths.h" #include "TextureResource.h" +#include "RenderingThread.h" +#include "Runtime/Launch/Resources/Version.h" #if PLATFORM_APPLE #include @@ -23,9 +24,7 @@ extern "C" #if PLATFORM_WINDOWS #include "Windows/AllowWindowsPlatformTypes.h" -#include "Windows/PreWindowsApi.h" #include -#include "Windows/PostWindowsApi.h" #include "Windows/HideWindowsPlatformTypes.h" #endif diff --git a/Source/UnrealLibretro/Private/LibretroContext.h b/Source/UnrealLibretro/Private/LibretroContext.h index a06cd66..cb6d36e 100644 --- a/Source/UnrealLibretro/Private/LibretroContext.h +++ b/Source/UnrealLibretro/Private/LibretroContext.h @@ -13,20 +13,21 @@ static_assert(RETRO_API_VERSION == 1, "Retro API version changed"); #include "Engine/TextureRenderTarget2D.h" #include "UObject/WeakObjectPtrTemplates.h" #include "Containers/CircularQueue.h" +#include "Containers/Queue.h" +#include "RHIResources.h" #include "LibretroInputDefinitions.h" #include "RawAudioSoundWave.h" #if PLATFORM_WINDOWS -#include "Windows/PreWindowsApi.h" -#include "Windows/WindowsHWrapper.h" +#include "Windows/AllowWindowsPlatformTypes.h" #endif #include "ThirdParty/OpenGL/GL/glcorearb.h" #include "GL/extension_definitions.h" #if PLATFORM_WINDOWS -#include "Windows/PostWindowsApi.h" +#include "Windows/HideWindowsPlatformTypes.h" #endif DECLARE_STATS_GROUP(TEXT("UnrealLibretro"), STATGROUP_UnrealLibretro, STATCAT_Advanced); diff --git a/Source/UnrealLibretro/Public/LibretroGameMode.h b/Source/UnrealLibretro/Public/LibretroGameMode.h index 0577540..e2a7402 100644 --- a/Source/UnrealLibretro/Public/LibretroGameMode.h +++ b/Source/UnrealLibretro/Public/LibretroGameMode.h @@ -28,7 +28,7 @@ class UNREALLIBRETRO_API ALibretroGameMode : public AGameModeBase // @todo There is probably some smarter way of determining this // This returns true if you launch PIE in "VR Preview" mode // If you start your packaged game with the flag -vr then this will also be true - static CONSTEXPR auto ShouldStartPlayerInVRPawn = UHeadMountedDisplayFunctionLibrary::IsHeadMountedDisplayEnabled; + static constexpr auto ShouldStartPlayerInVRPawn = UHeadMountedDisplayFunctionLibrary::IsHeadMountedDisplayEnabled; UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Classes) TSubclassOf DefaultVRPawnClass = ALibretroVRPawn::StaticClass(); diff --git a/Source/UnrealLibretro/Public/UnrealLibretro.h b/Source/UnrealLibretro/Public/UnrealLibretro.h index 5c062b0..924d26a 100644 --- a/Source/UnrealLibretro/Public/UnrealLibretro.h +++ b/Source/UnrealLibretro/Public/UnrealLibretro.h @@ -27,7 +27,6 @@ static const struct { FString DistributionPath; FString Extension; FString Build #if PLATFORM_WINDOWS #include "Windows/AllowWindowsPlatformTypes.h" -#include "Windows/PreWindowsApi.h" typedef HGLRC(WINAPI* PFN_wglCreateContext)(HDC); typedef BOOL(WINAPI* PFN_wglDeleteContext)(HGLRC); @@ -62,7 +61,6 @@ static void* Win32GLGetProcAddress(const char* procname) return proc; } -#include "Windows/PostWindowsApi.h" #include "Windows/HideWindowsPlatformTypes.h" #endif