From b95903164809162278efaf35e1f3e73f3bb658a8 Mon Sep 17 00:00:00 2001 From: Andron666 <> Date: Fri, 23 Oct 2020 18:01:01 +0500 Subject: [PATCH] add test project --- test/MyProject/Config/DefaultEditor.ini | 0 test/MyProject/Config/DefaultEngine.ini | 13 +++++++++++ test/MyProject/Config/DefaultGame.ini | 3 +++ test/MyProject/MyProject.uproject | 13 +++++++++++ test/MyProject/Source/MyProject.Target.cs | 14 +++++++++++ .../Source/MyProject/MyProject.Build.cs | 23 +++++++++++++++++++ test/MyProject/Source/MyProject/MyProject.cpp | 6 +++++ test/MyProject/Source/MyProject/MyProject.h | 6 +++++ .../MyProject/MyProjectGameModeBase.cpp | 2 +- .../Source/MyProject/MyProjectGameModeBase.h | 4 ++-- .../Source/MyProjectEditor.Target.cs | 14 +++++++++++ 11 files changed, 95 insertions(+), 3 deletions(-) create mode 100644 test/MyProject/Config/DefaultEditor.ini create mode 100644 test/MyProject/Config/DefaultEngine.ini create mode 100644 test/MyProject/Config/DefaultGame.ini create mode 100644 test/MyProject/MyProject.uproject create mode 100644 test/MyProject/Source/MyProject.Target.cs create mode 100644 test/MyProject/Source/MyProject/MyProject.Build.cs create mode 100644 test/MyProject/Source/MyProject/MyProject.cpp create mode 100644 test/MyProject/Source/MyProject/MyProject.h rename Source/Onejsky4U/Onejsky4UGameModeBase.cpp => test/MyProject/Source/MyProject/MyProjectGameModeBase.cpp (60%) rename Source/Onejsky4U/Onejsky4UGameModeBase.h => test/MyProject/Source/MyProject/MyProjectGameModeBase.h (62%) create mode 100644 test/MyProject/Source/MyProjectEditor.Target.cs diff --git a/test/MyProject/Config/DefaultEditor.ini b/test/MyProject/Config/DefaultEditor.ini new file mode 100644 index 00000000..e69de29b diff --git a/test/MyProject/Config/DefaultEngine.ini b/test/MyProject/Config/DefaultEngine.ini new file mode 100644 index 00000000..82a1f332 --- /dev/null +++ b/test/MyProject/Config/DefaultEngine.ini @@ -0,0 +1,13 @@ + + +[/Script/HardwareTargeting.HardwareTargetingSettings] +TargetedHardwareClass=Desktop +AppliedTargetedHardwareClass=Desktop +DefaultGraphicsPerformance=Maximum +AppliedDefaultGraphicsPerformance=Maximum + +[/Script/Engine.Engine] ++ActiveGameNameRedirects=(OldGameName="TP_Blank",NewGameName="/Script/MyProject") ++ActiveGameNameRedirects=(OldGameName="/Script/TP_Blank",NewGameName="/Script/MyProject") ++ActiveClassRedirects=(OldClassName="TP_BlankGameModeBase",NewClassName="MyProjectGameModeBase") + diff --git a/test/MyProject/Config/DefaultGame.ini b/test/MyProject/Config/DefaultGame.ini new file mode 100644 index 00000000..7e436167 --- /dev/null +++ b/test/MyProject/Config/DefaultGame.ini @@ -0,0 +1,3 @@ + +[/Script/EngineSettings.GeneralProjectSettings] +ProjectID=E96A3C56407960CEDD4B62B4D78B5DF6 diff --git a/test/MyProject/MyProject.uproject b/test/MyProject/MyProject.uproject new file mode 100644 index 00000000..a3c74699 --- /dev/null +++ b/test/MyProject/MyProject.uproject @@ -0,0 +1,13 @@ +{ + "FileVersion": 3, + "EngineAssociation": "4.25", + "Category": "", + "Description": "", + "Modules": [ + { + "Name": "MyProject", + "Type": "Runtime", + "LoadingPhase": "Default" + } + ] +} \ No newline at end of file diff --git a/test/MyProject/Source/MyProject.Target.cs b/test/MyProject/Source/MyProject.Target.cs new file mode 100644 index 00000000..e3e4b6e8 --- /dev/null +++ b/test/MyProject/Source/MyProject.Target.cs @@ -0,0 +1,14 @@ +// Copyright Epic Games, Inc. All Rights Reserved. + +using UnrealBuildTool; +using System.Collections.Generic; + +public class MyProjectTarget : TargetRules +{ + public MyProjectTarget( TargetInfo Target) : base(Target) + { + Type = TargetType.Game; + DefaultBuildSettings = BuildSettingsVersion.V2; + ExtraModuleNames.AddRange( new string[] { "MyProject" } ); + } +} diff --git a/test/MyProject/Source/MyProject/MyProject.Build.cs b/test/MyProject/Source/MyProject/MyProject.Build.cs new file mode 100644 index 00000000..2d594e5c --- /dev/null +++ b/test/MyProject/Source/MyProject/MyProject.Build.cs @@ -0,0 +1,23 @@ +// Copyright Epic Games, Inc. All Rights Reserved. + +using UnrealBuildTool; + +public class MyProject : ModuleRules +{ + public MyProject(ReadOnlyTargetRules Target) : base(Target) + { + PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs; + + PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore" }); + + PrivateDependencyModuleNames.AddRange(new string[] { }); + + // Uncomment if you are using Slate UI + // PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" }); + + // Uncomment if you are using online features + // PrivateDependencyModuleNames.Add("OnlineSubsystem"); + + // To include OnlineSubsystemSteam, add it to the plugins section in your uproject file with the Enabled attribute set to true + } +} diff --git a/test/MyProject/Source/MyProject/MyProject.cpp b/test/MyProject/Source/MyProject/MyProject.cpp new file mode 100644 index 00000000..b9d80b7f --- /dev/null +++ b/test/MyProject/Source/MyProject/MyProject.cpp @@ -0,0 +1,6 @@ +// Copyright Epic Games, Inc. All Rights Reserved. + +#include "MyProject.h" +#include "Modules/ModuleManager.h" + +IMPLEMENT_PRIMARY_GAME_MODULE( FDefaultGameModuleImpl, MyProject, "MyProject" ); diff --git a/test/MyProject/Source/MyProject/MyProject.h b/test/MyProject/Source/MyProject/MyProject.h new file mode 100644 index 00000000..677c8e25 --- /dev/null +++ b/test/MyProject/Source/MyProject/MyProject.h @@ -0,0 +1,6 @@ +// Copyright Epic Games, Inc. All Rights Reserved. + +#pragma once + +#include "CoreMinimal.h" + diff --git a/Source/Onejsky4U/Onejsky4UGameModeBase.cpp b/test/MyProject/Source/MyProject/MyProjectGameModeBase.cpp similarity index 60% rename from Source/Onejsky4U/Onejsky4UGameModeBase.cpp rename to test/MyProject/Source/MyProject/MyProjectGameModeBase.cpp index 66d643dc..39271c40 100644 --- a/Source/Onejsky4U/Onejsky4UGameModeBase.cpp +++ b/test/MyProject/Source/MyProject/MyProjectGameModeBase.cpp @@ -1,5 +1,5 @@ // Copyright Epic Games, Inc. All Rights Reserved. -#include "Onejsky4UGameModeBase.h" +#include "MyProjectGameModeBase.h" diff --git a/Source/Onejsky4U/Onejsky4UGameModeBase.h b/test/MyProject/Source/MyProject/MyProjectGameModeBase.h similarity index 62% rename from Source/Onejsky4U/Onejsky4UGameModeBase.h rename to test/MyProject/Source/MyProject/MyProjectGameModeBase.h index 9f12ca3d..f8b788bd 100644 --- a/Source/Onejsky4U/Onejsky4UGameModeBase.h +++ b/test/MyProject/Source/MyProject/MyProjectGameModeBase.h @@ -4,13 +4,13 @@ #include "CoreMinimal.h" #include "GameFramework/GameModeBase.h" -#include "Onejsky4UGameModeBase.generated.h" +#include "MyProjectGameModeBase.generated.h" /** * */ UCLASS() -class ONEJSKY4U_API AOnejsky4UGameModeBase : public AGameModeBase +class MYPROJECT_API AMyProjectGameModeBase : public AGameModeBase { GENERATED_BODY() diff --git a/test/MyProject/Source/MyProjectEditor.Target.cs b/test/MyProject/Source/MyProjectEditor.Target.cs new file mode 100644 index 00000000..d5bff6ac --- /dev/null +++ b/test/MyProject/Source/MyProjectEditor.Target.cs @@ -0,0 +1,14 @@ +// Copyright Epic Games, Inc. All Rights Reserved. + +using UnrealBuildTool; +using System.Collections.Generic; + +public class MyProjectEditorTarget : TargetRules +{ + public MyProjectEditorTarget( TargetInfo Target) : base(Target) + { + Type = TargetType.Editor; + DefaultBuildSettings = BuildSettingsVersion.V2; + ExtraModuleNames.AddRange( new string[] { "MyProject" } ); + } +}