Compare commits
22 Commits
5bfc79cbda
...
new/API_Ga
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
102a514afa | ||
|
|
41d61d883a | ||
|
|
734f859059 | ||
|
|
c8face6f9f | ||
|
|
d3c28f8330 | ||
|
|
34ef566665 | ||
|
|
6bf5d4cd0c | ||
|
|
1e5885ac26 | ||
|
|
62243acf46 | ||
|
|
a487c71b44 | ||
|
|
2805d7fb92 | ||
|
|
0fecdf2df7 | ||
|
|
f093212884 | ||
|
|
241b78fa4a | ||
|
|
4121a3925f | ||
|
|
7f14cad36f | ||
|
|
6afd336bbf | ||
|
|
554c94a778 | ||
|
|
23bcff131a | ||
|
|
51e89e8613 | ||
|
|
bf2ead5f97 | ||
|
|
04f5cb37dc |
4
.gitignore
vendored
4
.gitignore
vendored
@@ -70,3 +70,7 @@ Plugins/**/Intermediate/*
|
|||||||
|
|
||||||
# Cache files for the editor to use
|
# Cache files for the editor to use
|
||||||
DerivedDataCache/*
|
DerivedDataCache/*
|
||||||
|
|
||||||
|
# IDE Settings
|
||||||
|
.idea/
|
||||||
|
*.iml
|
||||||
15
.idea/.idea.FPSTemplate.dir/.idea/.gitignore
generated
vendored
15
.idea/.idea.FPSTemplate.dir/.idea/.gitignore
generated
vendored
@@ -1,15 +0,0 @@
|
|||||||
# Default ignored files
|
|
||||||
/shelf/
|
|
||||||
/workspace.xml
|
|
||||||
# Rider ignored files
|
|
||||||
/.idea.FPSTemplate.iml
|
|
||||||
/modules.xml
|
|
||||||
/contentModel.xml
|
|
||||||
/projectSettingsUpdater.xml
|
|
||||||
# Ignored default folder with query files
|
|
||||||
/queries/
|
|
||||||
# Datasource local storage ignored files
|
|
||||||
/dataSources/
|
|
||||||
/dataSources.local.xml
|
|
||||||
# Editor-based HTTP Client requests
|
|
||||||
/httpRequests/
|
|
||||||
4
.idea/.idea.FPSTemplate.dir/.idea/encodings.xml
generated
4
.idea/.idea.FPSTemplate.dir/.idea/encodings.xml
generated
@@ -1,4 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="Encoding" addBOMForNewFiles="with BOM under Windows, with no BOM otherwise" />
|
|
||||||
</project>
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="UserContentModel">
|
|
||||||
<attachedFolders />
|
|
||||||
<explicitIncludes />
|
|
||||||
<explicitExcludes />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
6
.idea/.idea.FPSTemplate.dir/.idea/vcs.xml
generated
6
.idea/.idea.FPSTemplate.dir/.idea/vcs.xml
generated
@@ -1,6 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="VcsDirectoryMappings">
|
|
||||||
<mapping directory="" vcs="Git" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
189
Config.bak/DefaultEngine.ini
Normal file
189
Config.bak/DefaultEngine.ini
Normal file
@@ -0,0 +1,189 @@
|
|||||||
|
[SystemSettings]
|
||||||
|
CommonUI.Debug.CheckGameViewportClientValid=0
|
||||||
|
|
||||||
|
[/Script/EngineSettings.GameMapsSettings]
|
||||||
|
GameDefaultMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
||||||
|
EditorStartupMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
||||||
|
GlobalDefaultGameMode=/Game/Blueprints/Game/BP_ShooterGameModeBase.BP_ShooterGameModeBase_C
|
||||||
|
ServerDefaultMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
||||||
|
|
||||||
|
[/Script/WindowsTargetPlatform.WindowsTargetSettings]
|
||||||
|
DefaultGraphicsRHI=DefaultGraphicsRHI_DX12
|
||||||
|
-D3D12TargetedShaderFormats=PCD3D_SM5
|
||||||
|
+D3D12TargetedShaderFormats=PCD3D_SM6
|
||||||
|
-D3D11TargetedShaderFormats=PCD3D_SM5
|
||||||
|
+D3D11TargetedShaderFormats=PCD3D_SM5
|
||||||
|
Compiler=Default
|
||||||
|
AudioSampleRate=48000
|
||||||
|
AudioCallbackBufferFrameSize=1024
|
||||||
|
AudioNumBuffersToEnqueue=1
|
||||||
|
AudioMaxChannels=0
|
||||||
|
AudioNumSourceWorkers=4
|
||||||
|
SpatializationPlugin=
|
||||||
|
SourceDataOverridePlugin=
|
||||||
|
ReverbPlugin=
|
||||||
|
OcclusionPlugin=
|
||||||
|
CompressionOverrides=(bOverrideCompressionTimes=False,DurationThreshold=5.000000,MaxNumRandomBranches=0,SoundCueQualityIndex=0)
|
||||||
|
CacheSizeKB=65536
|
||||||
|
MaxChunkSizeOverrideKB=0
|
||||||
|
bResampleForDevice=False
|
||||||
|
MaxSampleRate=48000.000000
|
||||||
|
HighSampleRate=32000.000000
|
||||||
|
MedSampleRate=24000.000000
|
||||||
|
LowSampleRate=12000.000000
|
||||||
|
MinSampleRate=8000.000000
|
||||||
|
CompressionQualityModifier=1.000000
|
||||||
|
AutoStreamingThreshold=0.000000
|
||||||
|
SoundCueCookQualityIndex=-1
|
||||||
|
|
||||||
|
[/Script/Engine.RendererSettings]
|
||||||
|
r.Mobile.EnableNoPrecomputedLightingCSMShader=True
|
||||||
|
|
||||||
|
r.GenerateMeshDistanceFields=True
|
||||||
|
|
||||||
|
r.DynamicGlobalIlluminationMethod=1
|
||||||
|
|
||||||
|
r.ReflectionMethod=1
|
||||||
|
|
||||||
|
r.Shadow.Virtual.Enable=1
|
||||||
|
|
||||||
|
r.DefaultFeature.AutoExposure.ExtendDefaultLuminanceRange=True
|
||||||
|
|
||||||
|
r.DefaultFeature.LocalExposure.HighlightContrastScale=0.8
|
||||||
|
|
||||||
|
r.DefaultFeature.LocalExposure.ShadowContrastScale=0.8
|
||||||
|
r.DefaultFeature.MotionBlur=False
|
||||||
|
|
||||||
|
[/Script/LinuxTargetPlatform.LinuxTargetSettings]
|
||||||
|
-TargetedRHIs=SF_VULKAN_SM5
|
||||||
|
+TargetedRHIs=SF_VULKAN_SM6
|
||||||
|
|
||||||
|
[/Script/HardwareTargeting.HardwareTargetingSettings]
|
||||||
|
TargetedHardwareClass=Desktop
|
||||||
|
AppliedTargetedHardwareClass=Desktop
|
||||||
|
DefaultGraphicsPerformance=Maximum
|
||||||
|
AppliedDefaultGraphicsPerformance=Maximum
|
||||||
|
|
||||||
|
[/Script/WorldPartitionEditor.WorldPartitionEditorSettings]
|
||||||
|
CommandletClass=Class'/Script/UnrealEd.WorldPartitionConvertCommandlet'
|
||||||
|
|
||||||
|
[/Script/Engine.UserInterfaceSettings]
|
||||||
|
bAuthorizeAutomaticWidgetVariableCreation=False
|
||||||
|
FontDPIPreset=Standard
|
||||||
|
FontDPI=72
|
||||||
|
|
||||||
|
[/Script/Engine.Engine]
|
||||||
|
+ActiveGameNameRedirects=(OldGameName="TP_Blank",NewGameName="/Script/FPSTemplate")
|
||||||
|
+ActiveGameNameRedirects=(OldGameName="/Script/TP_Blank",NewGameName="/Script/FPSTemplate")
|
||||||
|
|
||||||
|
[/Script/AndroidFileServerEditor.AndroidFileServerRuntimeSettings]
|
||||||
|
bEnablePlugin=True
|
||||||
|
bAllowNetworkConnection=True
|
||||||
|
SecurityToken=62442D434388E2324BF7AFB7F208A9F3
|
||||||
|
bIncludeInShipping=False
|
||||||
|
bAllowExternalStartInShipping=False
|
||||||
|
bCompileAFSProject=False
|
||||||
|
bUseCompression=False
|
||||||
|
bLogFiles=False
|
||||||
|
bReportStats=False
|
||||||
|
ConnectionType=USBOnly
|
||||||
|
bUseManualIPAddress=False
|
||||||
|
ManualIPAddress=
|
||||||
|
|
||||||
|
[/Script/Engine.CollisionProfile]
|
||||||
|
-Profiles=(Name="NoCollision",CollisionEnabled=NoCollision,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="No collision",bCanModify=False)
|
||||||
|
-Profiles=(Name="BlockAll",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldStatic",CustomResponses=,HelpMessage="WorldStatic object that blocks all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="OverlapAll",CollisionEnabled=QueryOnly,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="BlockAllDynamic",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldDynamic",CustomResponses=,HelpMessage="WorldDynamic object that blocks all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="OverlapAllDynamic",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="IgnoreOnlyPawn",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that ignores Pawn and Vehicle. All other channels will be set to default.",bCanModify=False)
|
||||||
|
-Profiles=(Name="OverlapOnlyPawn",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that overlaps Pawn, Camera, and Vehicle. All other channels will be set to default. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="Pawn",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Pawn",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object. Can be used for capsule of any playerable character or AI. ",bCanModify=False)
|
||||||
|
-Profiles=(Name="Spectator",CollisionEnabled=QueryOnly,ObjectTypeName="Pawn",CustomResponses=((Channel="WorldStatic",Response=ECR_Block),(Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore)),HelpMessage="Pawn object that ignores all other actors except WorldStatic.",bCanModify=False)
|
||||||
|
-Profiles=(Name="CharacterMesh",CollisionEnabled=QueryOnly,ObjectTypeName="Pawn",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object that is used for Character Mesh. All other channels will be set to default.",bCanModify=False)
|
||||||
|
-Profiles=(Name="PhysicsActor",CollisionEnabled=QueryAndPhysics,ObjectTypeName="PhysicsBody",CustomResponses=,HelpMessage="Simulating actors",bCanModify=False)
|
||||||
|
-Profiles=(Name="Destructible",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Destructible",CustomResponses=,HelpMessage="Destructible actors",bCanModify=False)
|
||||||
|
-Profiles=(Name="InvisibleWall",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldStatic object that is invisible.",bCanModify=False)
|
||||||
|
-Profiles=(Name="InvisibleWallDynamic",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that is invisible.",bCanModify=False)
|
||||||
|
-Profiles=(Name="Trigger",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that is used for trigger. All other channels will be set to default.",bCanModify=False)
|
||||||
|
-Profiles=(Name="Ragdoll",CollisionEnabled=QueryAndPhysics,ObjectTypeName="PhysicsBody",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Simulating Skeletal Mesh Component. All other channels will be set to default.",bCanModify=False)
|
||||||
|
-Profiles=(Name="Vehicle",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Vehicle",CustomResponses=,HelpMessage="Vehicle object that blocks Vehicle, WorldStatic, and WorldDynamic. All other channels will be set to default.",bCanModify=False)
|
||||||
|
-Profiles=(Name="UI",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Block),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
||||||
|
+Profiles=(Name="NoCollision",CollisionEnabled=NoCollision,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="No collision")
|
||||||
|
+Profiles=(Name="BlockAll",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=,HelpMessage="WorldStatic object that blocks all actors by default. All new custom channels will use its own default response. ")
|
||||||
|
+Profiles=(Name="OverlapAll",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
||||||
|
+Profiles=(Name="BlockAllDynamic",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=,HelpMessage="WorldDynamic object that blocks all actors by default. All new custom channels will use its own default response. ")
|
||||||
|
+Profiles=(Name="OverlapAllDynamic",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
||||||
|
+Profiles=(Name="IgnoreOnlyPawn",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that ignores Pawn and Vehicle. All other channels will be set to default.")
|
||||||
|
+Profiles=(Name="OverlapOnlyPawn",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that overlaps Pawn, Camera, and Vehicle. All other channels will be set to default. ")
|
||||||
|
+Profiles=(Name="Pawn",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object. Can be used for capsule of any playerable character or AI. ")
|
||||||
|
+Profiles=(Name="Spectator",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="WorldStatic"),(Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore)),HelpMessage="Pawn object that ignores all other actors except WorldStatic.")
|
||||||
|
+Profiles=(Name="CharacterMesh",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object that is used for Character Mesh. All other channels will be set to default.")
|
||||||
|
+Profiles=(Name="PhysicsActor",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="PhysicsBody",CustomResponses=,HelpMessage="Simulating actors")
|
||||||
|
+Profiles=(Name="Destructible",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Destructible",CustomResponses=,HelpMessage="Destructible actors")
|
||||||
|
+Profiles=(Name="InvisibleWall",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldStatic object that is invisible.")
|
||||||
|
+Profiles=(Name="InvisibleWallDynamic",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that is invisible.")
|
||||||
|
+Profiles=(Name="Trigger",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that is used for trigger. All other channels will be set to default.")
|
||||||
|
+Profiles=(Name="Ragdoll",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="PhysicsBody",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Simulating Skeletal Mesh Component. All other channels will be set to default.")
|
||||||
|
+Profiles=(Name="Vehicle",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Vehicle",CustomResponses=,HelpMessage="Vehicle object that blocks Vehicle, WorldStatic, and WorldDynamic. All other channels will be set to default.")
|
||||||
|
+Profiles=(Name="UI",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility"),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
||||||
|
+Profiles=(Name="Pickup",CollisionEnabled=QueryOnly,bCanModify=True,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore),(Channel="Weapon",Response=ECR_Ignore)),HelpMessage="Only overlaps with Pawn")
|
||||||
|
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel1,DefaultResponse=ECR_Block,bTraceType=True,bStaticObject=False,Name="Weapon")
|
||||||
|
+EditProfiles=(Name="Pawn",CustomResponses=((Channel="Weapon",Response=ECR_Ignore)))
|
||||||
|
-ProfileRedirects=(OldName="BlockingVolume",NewName="InvisibleWall")
|
||||||
|
-ProfileRedirects=(OldName="InterpActor",NewName="IgnoreOnlyPawn")
|
||||||
|
-ProfileRedirects=(OldName="StaticMeshComponent",NewName="BlockAllDynamic")
|
||||||
|
-ProfileRedirects=(OldName="SkeletalMeshActor",NewName="PhysicsActor")
|
||||||
|
-ProfileRedirects=(OldName="InvisibleActor",NewName="InvisibleWallDynamic")
|
||||||
|
+ProfileRedirects=(OldName="BlockingVolume",NewName="InvisibleWall")
|
||||||
|
+ProfileRedirects=(OldName="InterpActor",NewName="IgnoreOnlyPawn")
|
||||||
|
+ProfileRedirects=(OldName="StaticMeshComponent",NewName="BlockAllDynamic")
|
||||||
|
+ProfileRedirects=(OldName="SkeletalMeshActor",NewName="PhysicsActor")
|
||||||
|
+ProfileRedirects=(OldName="InvisibleActor",NewName="InvisibleWallDynamic")
|
||||||
|
-CollisionChannelRedirects=(OldName="Static",NewName="WorldStatic")
|
||||||
|
-CollisionChannelRedirects=(OldName="Dynamic",NewName="WorldDynamic")
|
||||||
|
-CollisionChannelRedirects=(OldName="VehicleMovement",NewName="Vehicle")
|
||||||
|
-CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")
|
||||||
|
+CollisionChannelRedirects=(OldName="Static",NewName="WorldStatic")
|
||||||
|
+CollisionChannelRedirects=(OldName="Dynamic",NewName="WorldDynamic")
|
||||||
|
+CollisionChannelRedirects=(OldName="VehicleMovement",NewName="Vehicle")
|
||||||
|
+CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")
|
||||||
|
|
||||||
|
[/Script/Engine.PhysicsSettings]
|
||||||
|
PhysicsPrediction=(bEnablePhysicsPrediction=False,bEnablePhysicsResimulation=False,ResimulationErrorThreshold=10.000000,MaxSupportedLatencyPrediction=1000.000000)
|
||||||
|
PhysicErrorCorrection=(PingExtrapolation=0.100000,PingLimit=100.000000,ErrorPerLinearDifference=1.000000,ErrorPerAngularDifference=1.000000,MaxRestoredStateError=1.000000,MaxLinearHardSnapDistance=400.000000,PositionLerp=0.000000,AngleLerp=0.400000,LinearVelocityCoefficient=100.000000,AngularVelocityCoefficient=10.000000,ErrorAccumulationSeconds=0.500000,ErrorAccumulationDistanceSq=15.000000,ErrorAccumulationSimilarity=100.000000)
|
||||||
|
DefaultDegreesOfFreedom=Full3D
|
||||||
|
bSuppressFaceRemapTable=False
|
||||||
|
bSupportUVFromHitResults=False
|
||||||
|
bDisableActiveActors=False
|
||||||
|
bDisableKinematicStaticPairs=False
|
||||||
|
bDisableKinematicKinematicPairs=False
|
||||||
|
bDisableCCD=False
|
||||||
|
AnimPhysicsMinDeltaTime=0.000000
|
||||||
|
bSimulateAnimPhysicsAfterReset=False
|
||||||
|
MinPhysicsDeltaTime=0.000000
|
||||||
|
MaxPhysicsDeltaTime=0.033333
|
||||||
|
bSubstepping=False
|
||||||
|
bSubsteppingAsync=False
|
||||||
|
bTickPhysicsAsync=False
|
||||||
|
AsyncFixedTimeStepSize=0.033333
|
||||||
|
MaxSubstepDeltaTime=0.016667
|
||||||
|
MaxSubsteps=6
|
||||||
|
SyncSceneSmoothingFactor=0.000000
|
||||||
|
InitialAverageFrameRate=0.016667
|
||||||
|
PhysXTreeRebuildRate=10
|
||||||
|
+PhysicalSurfaces=(Type=SurfaceType1,Name="Character")
|
||||||
|
+PhysicalSurfaces=(Type=SurfaceType2,Name="Concrete")
|
||||||
|
+PhysicalSurfaces=(Type=SurfaceType3,Name="Glass")
|
||||||
|
DefaultBroadphaseSettings=(bUseMBPOnClient=False,bUseMBPOnServer=False,bUseMBPOuterBounds=False,MBPBounds=(Min=(X=0.000000,Y=0.000000,Z=0.000000),Max=(X=0.000000,Y=0.000000,Z=0.000000),IsValid=False),MBPOuterBounds=(Min=(X=0.000000,Y=0.000000,Z=0.000000),Max=(X=0.000000,Y=0.000000,Z=0.000000),IsValid=False),MBPNumSubdivs=2)
|
||||||
|
MinDeltaVelocityForHitEvents=0.000000
|
||||||
|
ChaosSettings=(DefaultThreadingModel=TaskGraph,DedicatedThreadTickMode=VariableCappedWithTarget,DedicatedThreadBufferMode=Double)
|
||||||
|
|
||||||
|
[URL]
|
||||||
|
DefaultPort=7777
|
||||||
|
|
||||||
|
[CoreRedirects]
|
||||||
|
+EnumRedirects=(OldName="/Script/FPSTemplate.EvalidationError",NewName="/Script/FPSTemplate.EValidationError")
|
||||||
|
+FunctionRedirects=(OldName="/Script/FPSTemplate.GameLiftValidators.LogValidataErrorMessage",NewName="/Script/FPSTemplate.GameLiftValidators.LogValidationErrorMessage")
|
||||||
|
;+PropertyRedirects=(OldName="/Script/FPSTemplate.CommandLineArgs.Arguments",NewName="/Script/FPSTemplate.CommandLineArgs.CmdArguments")
|
||||||
|
|
||||||
99
Config.bak/DefaultInput.ini
Normal file
99
Config.bak/DefaultInput.ini
Normal file
@@ -0,0 +1,99 @@
|
|||||||
|
[/Script/Engine.InputSettings]
|
||||||
|
-AxisConfig=(AxisKeyName="Gamepad_LeftX",AxisProperties=(DeadZone=0.25,Exponent=1.f,Sensitivity=1.f))
|
||||||
|
-AxisConfig=(AxisKeyName="Gamepad_LeftY",AxisProperties=(DeadZone=0.25,Exponent=1.f,Sensitivity=1.f))
|
||||||
|
-AxisConfig=(AxisKeyName="Gamepad_RightX",AxisProperties=(DeadZone=0.25,Exponent=1.f,Sensitivity=1.f))
|
||||||
|
-AxisConfig=(AxisKeyName="Gamepad_RightY",AxisProperties=(DeadZone=0.25,Exponent=1.f,Sensitivity=1.f))
|
||||||
|
-AxisConfig=(AxisKeyName="MouseX",AxisProperties=(DeadZone=0.f,Exponent=1.f,Sensitivity=0.07f))
|
||||||
|
-AxisConfig=(AxisKeyName="MouseY",AxisProperties=(DeadZone=0.f,Exponent=1.f,Sensitivity=0.07f))
|
||||||
|
-AxisConfig=(AxisKeyName="Mouse2D",AxisProperties=(DeadZone=0.f,Exponent=1.f,Sensitivity=0.07f))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_LeftX",AxisProperties=(DeadZone=0.250000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_LeftY",AxisProperties=(DeadZone=0.250000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_RightX",AxisProperties=(DeadZone=0.250000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_RightY",AxisProperties=(DeadZone=0.250000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MouseX",AxisProperties=(DeadZone=0.000000,Sensitivity=0.070000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MouseY",AxisProperties=(DeadZone=0.000000,Sensitivity=0.070000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Mouse2D",AxisProperties=(DeadZone=0.000000,Sensitivity=0.070000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MouseWheelAxis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_LeftTriggerAxis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_RightTriggerAxis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_Special_Left_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Gamepad_Special_Left_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Left_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Left_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Left_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Right_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Right_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="Vive_Right_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Left_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Left_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Left_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Left_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Left_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Right_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Right_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Right_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Right_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="MixedReality_Right_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Left_Grip_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Left_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Left_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Left_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Right_Grip_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Right_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Right_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="OculusTouch_Right_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Grip_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Grip_Force",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Left_Trackpad_Force",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Grip_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Grip_Force",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Trigger_Axis",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Thumbstick_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Thumbstick_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Trackpad_X",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Trackpad_Y",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
+AxisConfig=(AxisKeyName="ValveIndex_Right_Trackpad_Force",AxisProperties=(DeadZone=0.000000,Sensitivity=1.000000,Exponent=1.000000,bInvert=False))
|
||||||
|
bAltEnterTogglesFullscreen=True
|
||||||
|
bF11TogglesFullscreen=True
|
||||||
|
bUseMouseForTouch=False
|
||||||
|
bEnableMouseSmoothing=True
|
||||||
|
bEnableFOVScaling=True
|
||||||
|
bCaptureMouseOnLaunch=True
|
||||||
|
bEnableLegacyInputScales=True
|
||||||
|
bEnableMotionControls=True
|
||||||
|
bFilterInputByPlatformUser=False
|
||||||
|
bEnableInputDeviceSubsystem=True
|
||||||
|
bShouldFlushPressedKeysOnViewportFocusLost=True
|
||||||
|
bEnableDynamicComponentInputBinding=True
|
||||||
|
bAlwaysShowTouchInterface=False
|
||||||
|
bShowConsoleOnFourFingerTap=True
|
||||||
|
bEnableGestureRecognizer=False
|
||||||
|
bUseAutocorrect=False
|
||||||
|
DefaultViewportMouseCaptureMode=CapturePermanently_IncludingInitialMouseDown
|
||||||
|
DefaultViewportMouseLockMode=LockOnCapture
|
||||||
|
FOVScale=0.011110
|
||||||
|
DoubleClickTime=0.200000
|
||||||
|
+ActionMappings=(ActionName="Jump",bShift=False,bCtrl=False,bAlt=False,bCmd=False,Key=Gamepad_FaceButton_Bottom)
|
||||||
|
+ActionMappings=(ActionName="Jump",bShift=False,bCtrl=False,bAlt=False,bCmd=False,Key=SpaceBar)
|
||||||
|
+AxisMappings=(AxisName="Look Up / Down Gamepad",Scale=1.000000,Key=Gamepad_RightY)
|
||||||
|
+AxisMappings=(AxisName="Look Up / Down Mouse",Scale=-1.000000,Key=MouseY)
|
||||||
|
+AxisMappings=(AxisName="Move Forward / Backward",Scale=1.000000,Key=Gamepad_LeftY)
|
||||||
|
+AxisMappings=(AxisName="Move Forward / Backward",Scale=-1.000000,Key=S)
|
||||||
|
+AxisMappings=(AxisName="Move Forward / Backward",Scale=1.000000,Key=W)
|
||||||
|
+AxisMappings=(AxisName="Move Right / Left",Scale=-1.000000,Key=A)
|
||||||
|
+AxisMappings=(AxisName="Move Right / Left",Scale=1.000000,Key=D)
|
||||||
|
+AxisMappings=(AxisName="Move Right / Left",Scale=1.000000,Key=Gamepad_LeftX)
|
||||||
|
+AxisMappings=(AxisName="Turn Right / Left Gamepad",Scale=1.000000,Key=Gamepad_RightX)
|
||||||
|
+AxisMappings=(AxisName="Turn Right / Left Mouse",Scale=1.000000,Key=MouseX)
|
||||||
|
DefaultPlayerInputClass=/Script/EnhancedInput.EnhancedPlayerInput
|
||||||
|
DefaultInputComponentClass=/Script/EnhancedInput.EnhancedInputComponent
|
||||||
|
DefaultTouchInterface=/Engine/MobileResources/HUD/DefaultVirtualJoysticks.DefaultVirtualJoysticks
|
||||||
|
-ConsoleKeys=Tilde
|
||||||
|
+ConsoleKeys=Tilde
|
||||||
|
+ConsoleKeys=Caret
|
||||||
|
|
||||||
@@ -1,18 +1,25 @@
|
|||||||
[SystemSettings]
|
[/Script/AndroidFileServerEditor.AndroidFileServerRuntimeSettings]
|
||||||
CommonUI.Debug.CheckGameViewportClientValid=0
|
bEnablePlugin=True
|
||||||
|
bAllowNetworkConnection=True
|
||||||
[/Script/EngineSettings.GameMapsSettings]
|
SecurityToken=84E00C58412CE2A05A24C09DC3639CFC
|
||||||
GameDefaultMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
bIncludeInShipping=False
|
||||||
EditorStartupMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
bAllowExternalStartInShipping=False
|
||||||
GlobalDefaultGameMode=/Game/Blueprints/Game/BP_ShooterGameMode.BP_ShooterGameMode_C
|
bCompileAFSProject=False
|
||||||
ServerDefaultMap=/Game/ThirdPerson/Maps/ThirdPersonMap.ThirdPersonMap
|
bUseCompression=False
|
||||||
|
bLogFiles=False
|
||||||
|
bReportStats=False
|
||||||
|
ConnectionType=USBOnly
|
||||||
|
bUseManualIPAddress=False
|
||||||
|
ManualIPAddress=
|
||||||
|
|
||||||
[/Script/WindowsTargetPlatform.WindowsTargetSettings]
|
[/Script/WindowsTargetPlatform.WindowsTargetSettings]
|
||||||
DefaultGraphicsRHI=DefaultGraphicsRHI_DX12
|
DefaultGraphicsRHI=DefaultGraphicsRHI_Default
|
||||||
-D3D12TargetedShaderFormats=PCD3D_SM5
|
-D3D12TargetedShaderFormats=PCD3D_SM5
|
||||||
|
+D3D12TargetedShaderFormats=PCD3D_SM5
|
||||||
+D3D12TargetedShaderFormats=PCD3D_SM6
|
+D3D12TargetedShaderFormats=PCD3D_SM6
|
||||||
-D3D11TargetedShaderFormats=PCD3D_SM5
|
-D3D11TargetedShaderFormats=PCD3D_SM5
|
||||||
+D3D11TargetedShaderFormats=PCD3D_SM5
|
+D3D11TargetedShaderFormats=PCD3D_SM5
|
||||||
|
bGenerateNaniteFallbackMeshes=True
|
||||||
Compiler=Default
|
Compiler=Default
|
||||||
AudioSampleRate=48000
|
AudioSampleRate=48000
|
||||||
AudioCallbackBufferFrameSize=1024
|
AudioCallbackBufferFrameSize=1024
|
||||||
@@ -36,149 +43,7 @@ CompressionQualityModifier=1.000000
|
|||||||
AutoStreamingThreshold=0.000000
|
AutoStreamingThreshold=0.000000
|
||||||
SoundCueCookQualityIndex=-1
|
SoundCueCookQualityIndex=-1
|
||||||
|
|
||||||
[/Script/Engine.RendererSettings]
|
[/Script/EngineSettings.GameMapsSettings]
|
||||||
r.Mobile.EnableNoPrecomputedLightingCSMShader=True
|
EditorStartupMap=/Game/Maps/StartupMap.StartupMap
|
||||||
|
GameDefaultMap=/Game/Maps/StartupMap.StartupMap
|
||||||
|
|
||||||
r.GenerateMeshDistanceFields=True
|
|
||||||
|
|
||||||
r.DynamicGlobalIlluminationMethod=1
|
|
||||||
|
|
||||||
r.ReflectionMethod=1
|
|
||||||
|
|
||||||
r.Shadow.Virtual.Enable=1
|
|
||||||
|
|
||||||
r.DefaultFeature.AutoExposure.ExtendDefaultLuminanceRange=True
|
|
||||||
|
|
||||||
r.DefaultFeature.LocalExposure.HighlightContrastScale=0.8
|
|
||||||
|
|
||||||
r.DefaultFeature.LocalExposure.ShadowContrastScale=0.8
|
|
||||||
r.DefaultFeature.MotionBlur=False
|
|
||||||
|
|
||||||
[/Script/LinuxTargetPlatform.LinuxTargetSettings]
|
|
||||||
-TargetedRHIs=SF_VULKAN_SM5
|
|
||||||
+TargetedRHIs=SF_VULKAN_SM6
|
|
||||||
|
|
||||||
[/Script/HardwareTargeting.HardwareTargetingSettings]
|
|
||||||
TargetedHardwareClass=Desktop
|
|
||||||
AppliedTargetedHardwareClass=Desktop
|
|
||||||
DefaultGraphicsPerformance=Maximum
|
|
||||||
AppliedDefaultGraphicsPerformance=Maximum
|
|
||||||
|
|
||||||
[/Script/WorldPartitionEditor.WorldPartitionEditorSettings]
|
|
||||||
CommandletClass=Class'/Script/UnrealEd.WorldPartitionConvertCommandlet'
|
|
||||||
|
|
||||||
[/Script/Engine.UserInterfaceSettings]
|
|
||||||
bAuthorizeAutomaticWidgetVariableCreation=False
|
|
||||||
FontDPIPreset=Standard
|
|
||||||
FontDPI=72
|
|
||||||
|
|
||||||
[/Script/Engine.Engine]
|
|
||||||
+ActiveGameNameRedirects=(OldGameName="TP_Blank",NewGameName="/Script/FPSTemplate")
|
|
||||||
+ActiveGameNameRedirects=(OldGameName="/Script/TP_Blank",NewGameName="/Script/FPSTemplate")
|
|
||||||
|
|
||||||
[/Script/AndroidFileServerEditor.AndroidFileServerRuntimeSettings]
|
|
||||||
bEnablePlugin=True
|
|
||||||
bAllowNetworkConnection=True
|
|
||||||
SecurityToken=62442D434388E2324BF7AFB7F208A9F3
|
|
||||||
bIncludeInShipping=False
|
|
||||||
bAllowExternalStartInShipping=False
|
|
||||||
bCompileAFSProject=False
|
|
||||||
bUseCompression=False
|
|
||||||
bLogFiles=False
|
|
||||||
bReportStats=False
|
|
||||||
ConnectionType=USBOnly
|
|
||||||
bUseManualIPAddress=False
|
|
||||||
ManualIPAddress=
|
|
||||||
|
|
||||||
[/Script/Engine.CollisionProfile]
|
|
||||||
-Profiles=(Name="NoCollision",CollisionEnabled=NoCollision,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="No collision",bCanModify=False)
|
|
||||||
-Profiles=(Name="BlockAll",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldStatic",CustomResponses=,HelpMessage="WorldStatic object that blocks all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="OverlapAll",CollisionEnabled=QueryOnly,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="BlockAllDynamic",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldDynamic",CustomResponses=,HelpMessage="WorldDynamic object that blocks all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="OverlapAllDynamic",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="IgnoreOnlyPawn",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that ignores Pawn and Vehicle. All other channels will be set to default.",bCanModify=False)
|
|
||||||
-Profiles=(Name="OverlapOnlyPawn",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that overlaps Pawn, Camera, and Vehicle. All other channels will be set to default. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="Pawn",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Pawn",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object. Can be used for capsule of any playerable character or AI. ",bCanModify=False)
|
|
||||||
-Profiles=(Name="Spectator",CollisionEnabled=QueryOnly,ObjectTypeName="Pawn",CustomResponses=((Channel="WorldStatic",Response=ECR_Block),(Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore)),HelpMessage="Pawn object that ignores all other actors except WorldStatic.",bCanModify=False)
|
|
||||||
-Profiles=(Name="CharacterMesh",CollisionEnabled=QueryOnly,ObjectTypeName="Pawn",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object that is used for Character Mesh. All other channels will be set to default.",bCanModify=False)
|
|
||||||
-Profiles=(Name="PhysicsActor",CollisionEnabled=QueryAndPhysics,ObjectTypeName="PhysicsBody",CustomResponses=,HelpMessage="Simulating actors",bCanModify=False)
|
|
||||||
-Profiles=(Name="Destructible",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Destructible",CustomResponses=,HelpMessage="Destructible actors",bCanModify=False)
|
|
||||||
-Profiles=(Name="InvisibleWall",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldStatic object that is invisible.",bCanModify=False)
|
|
||||||
-Profiles=(Name="InvisibleWallDynamic",CollisionEnabled=QueryAndPhysics,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that is invisible.",bCanModify=False)
|
|
||||||
-Profiles=(Name="Trigger",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that is used for trigger. All other channels will be set to default.",bCanModify=False)
|
|
||||||
-Profiles=(Name="Ragdoll",CollisionEnabled=QueryAndPhysics,ObjectTypeName="PhysicsBody",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Simulating Skeletal Mesh Component. All other channels will be set to default.",bCanModify=False)
|
|
||||||
-Profiles=(Name="Vehicle",CollisionEnabled=QueryAndPhysics,ObjectTypeName="Vehicle",CustomResponses=,HelpMessage="Vehicle object that blocks Vehicle, WorldStatic, and WorldDynamic. All other channels will be set to default.",bCanModify=False)
|
|
||||||
-Profiles=(Name="UI",CollisionEnabled=QueryOnly,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Block),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ",bCanModify=False)
|
|
||||||
+Profiles=(Name="NoCollision",CollisionEnabled=NoCollision,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="No collision")
|
|
||||||
+Profiles=(Name="BlockAll",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=,HelpMessage="WorldStatic object that blocks all actors by default. All new custom channels will use its own default response. ")
|
|
||||||
+Profiles=(Name="OverlapAll",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
|
||||||
+Profiles=(Name="BlockAllDynamic",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=,HelpMessage="WorldDynamic object that blocks all actors by default. All new custom channels will use its own default response. ")
|
|
||||||
+Profiles=(Name="OverlapAllDynamic",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Overlap),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
|
||||||
+Profiles=(Name="IgnoreOnlyPawn",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that ignores Pawn and Vehicle. All other channels will be set to default.")
|
|
||||||
+Profiles=(Name="OverlapOnlyPawn",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Pawn",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that overlaps Pawn, Camera, and Vehicle. All other channels will be set to default. ")
|
|
||||||
+Profiles=(Name="Pawn",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object. Can be used for capsule of any playerable character or AI. ")
|
|
||||||
+Profiles=(Name="Spectator",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="WorldStatic"),(Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore)),HelpMessage="Pawn object that ignores all other actors except WorldStatic.")
|
|
||||||
+Profiles=(Name="CharacterMesh",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="Pawn",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Pawn object that is used for Character Mesh. All other channels will be set to default.")
|
|
||||||
+Profiles=(Name="PhysicsActor",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="PhysicsBody",CustomResponses=,HelpMessage="Simulating actors")
|
|
||||||
+Profiles=(Name="Destructible",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Destructible",CustomResponses=,HelpMessage="Destructible actors")
|
|
||||||
+Profiles=(Name="InvisibleWall",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldStatic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldStatic object that is invisible.")
|
|
||||||
+Profiles=(Name="InvisibleWallDynamic",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="Visibility",Response=ECR_Ignore)),HelpMessage="WorldDynamic object that is invisible.")
|
|
||||||
+Profiles=(Name="Trigger",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldDynamic object that is used for trigger. All other channels will be set to default.")
|
|
||||||
+Profiles=(Name="Ragdoll",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="PhysicsBody",CustomResponses=((Channel="Pawn",Response=ECR_Ignore),(Channel="Visibility",Response=ECR_Ignore)),HelpMessage="Simulating Skeletal Mesh Component. All other channels will be set to default.")
|
|
||||||
+Profiles=(Name="Vehicle",CollisionEnabled=QueryAndPhysics,bCanModify=False,ObjectTypeName="Vehicle",CustomResponses=,HelpMessage="Vehicle object that blocks Vehicle, WorldStatic, and WorldDynamic. All other channels will be set to default.")
|
|
||||||
+Profiles=(Name="UI",CollisionEnabled=QueryOnly,bCanModify=False,ObjectTypeName="WorldDynamic",CustomResponses=((Channel="WorldStatic",Response=ECR_Overlap),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility"),(Channel="WorldDynamic",Response=ECR_Overlap),(Channel="Camera",Response=ECR_Overlap),(Channel="PhysicsBody",Response=ECR_Overlap),(Channel="Vehicle",Response=ECR_Overlap),(Channel="Destructible",Response=ECR_Overlap)),HelpMessage="WorldStatic object that overlaps all actors by default. All new custom channels will use its own default response. ")
|
|
||||||
+Profiles=(Name="Pickup",CollisionEnabled=QueryOnly,bCanModify=True,ObjectTypeName="WorldStatic",CustomResponses=((Channel="WorldStatic",Response=ECR_Ignore),(Channel="WorldDynamic",Response=ECR_Ignore),(Channel="Pawn",Response=ECR_Overlap),(Channel="Visibility",Response=ECR_Ignore),(Channel="Camera",Response=ECR_Ignore),(Channel="PhysicsBody",Response=ECR_Ignore),(Channel="Vehicle",Response=ECR_Ignore),(Channel="Destructible",Response=ECR_Ignore),(Channel="Weapon",Response=ECR_Ignore)),HelpMessage="Only overlaps with Pawn")
|
|
||||||
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel1,DefaultResponse=ECR_Block,bTraceType=True,bStaticObject=False,Name="Weapon")
|
|
||||||
+EditProfiles=(Name="Pawn",CustomResponses=((Channel="Weapon",Response=ECR_Ignore)))
|
|
||||||
-ProfileRedirects=(OldName="BlockingVolume",NewName="InvisibleWall")
|
|
||||||
-ProfileRedirects=(OldName="InterpActor",NewName="IgnoreOnlyPawn")
|
|
||||||
-ProfileRedirects=(OldName="StaticMeshComponent",NewName="BlockAllDynamic")
|
|
||||||
-ProfileRedirects=(OldName="SkeletalMeshActor",NewName="PhysicsActor")
|
|
||||||
-ProfileRedirects=(OldName="InvisibleActor",NewName="InvisibleWallDynamic")
|
|
||||||
+ProfileRedirects=(OldName="BlockingVolume",NewName="InvisibleWall")
|
|
||||||
+ProfileRedirects=(OldName="InterpActor",NewName="IgnoreOnlyPawn")
|
|
||||||
+ProfileRedirects=(OldName="StaticMeshComponent",NewName="BlockAllDynamic")
|
|
||||||
+ProfileRedirects=(OldName="SkeletalMeshActor",NewName="PhysicsActor")
|
|
||||||
+ProfileRedirects=(OldName="InvisibleActor",NewName="InvisibleWallDynamic")
|
|
||||||
-CollisionChannelRedirects=(OldName="Static",NewName="WorldStatic")
|
|
||||||
-CollisionChannelRedirects=(OldName="Dynamic",NewName="WorldDynamic")
|
|
||||||
-CollisionChannelRedirects=(OldName="VehicleMovement",NewName="Vehicle")
|
|
||||||
-CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")
|
|
||||||
+CollisionChannelRedirects=(OldName="Static",NewName="WorldStatic")
|
|
||||||
+CollisionChannelRedirects=(OldName="Dynamic",NewName="WorldDynamic")
|
|
||||||
+CollisionChannelRedirects=(OldName="VehicleMovement",NewName="Vehicle")
|
|
||||||
+CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")
|
|
||||||
|
|
||||||
[/Script/Engine.PhysicsSettings]
|
|
||||||
PhysicsPrediction=(bEnablePhysicsPrediction=False,bEnablePhysicsResimulation=False,ResimulationErrorThreshold=10.000000,MaxSupportedLatencyPrediction=1000.000000)
|
|
||||||
PhysicErrorCorrection=(PingExtrapolation=0.100000,PingLimit=100.000000,ErrorPerLinearDifference=1.000000,ErrorPerAngularDifference=1.000000,MaxRestoredStateError=1.000000,MaxLinearHardSnapDistance=400.000000,PositionLerp=0.000000,AngleLerp=0.400000,LinearVelocityCoefficient=100.000000,AngularVelocityCoefficient=10.000000,ErrorAccumulationSeconds=0.500000,ErrorAccumulationDistanceSq=15.000000,ErrorAccumulationSimilarity=100.000000)
|
|
||||||
DefaultDegreesOfFreedom=Full3D
|
|
||||||
bSuppressFaceRemapTable=False
|
|
||||||
bSupportUVFromHitResults=False
|
|
||||||
bDisableActiveActors=False
|
|
||||||
bDisableKinematicStaticPairs=False
|
|
||||||
bDisableKinematicKinematicPairs=False
|
|
||||||
bDisableCCD=False
|
|
||||||
AnimPhysicsMinDeltaTime=0.000000
|
|
||||||
bSimulateAnimPhysicsAfterReset=False
|
|
||||||
MinPhysicsDeltaTime=0.000000
|
|
||||||
MaxPhysicsDeltaTime=0.033333
|
|
||||||
bSubstepping=False
|
|
||||||
bSubsteppingAsync=False
|
|
||||||
bTickPhysicsAsync=False
|
|
||||||
AsyncFixedTimeStepSize=0.033333
|
|
||||||
MaxSubstepDeltaTime=0.016667
|
|
||||||
MaxSubsteps=6
|
|
||||||
SyncSceneSmoothingFactor=0.000000
|
|
||||||
InitialAverageFrameRate=0.016667
|
|
||||||
PhysXTreeRebuildRate=10
|
|
||||||
+PhysicalSurfaces=(Type=SurfaceType1,Name="Character")
|
|
||||||
+PhysicalSurfaces=(Type=SurfaceType2,Name="Concrete")
|
|
||||||
+PhysicalSurfaces=(Type=SurfaceType3,Name="Glass")
|
|
||||||
DefaultBroadphaseSettings=(bUseMBPOnClient=False,bUseMBPOnServer=False,bUseMBPOuterBounds=False,MBPBounds=(Min=(X=0.000000,Y=0.000000,Z=0.000000),Max=(X=0.000000,Y=0.000000,Z=0.000000),IsValid=False),MBPOuterBounds=(Min=(X=0.000000,Y=0.000000,Z=0.000000),Max=(X=0.000000,Y=0.000000,Z=0.000000),IsValid=False),MBPNumSubdivs=2)
|
|
||||||
MinDeltaVelocityForHitEvents=0.000000
|
|
||||||
ChaosSettings=(DefaultThreadingModel=TaskGraph,DedicatedThreadTickMode=VariableCappedWithTarget,DedicatedThreadBufferMode=Double)
|
|
||||||
|
|
||||||
|
|
||||||
[CoreRedirects]
|
|
||||||
+PropertyRedirects=(OldName="/Script/FPSTemplate.CommandLineArgs.Arguments",NewName="/Script/FPSTemplate.CommandLineArgs.CmdArguments")
|
|
||||||
@@ -67,33 +67,20 @@ bCaptureMouseOnLaunch=True
|
|||||||
bEnableLegacyInputScales=True
|
bEnableLegacyInputScales=True
|
||||||
bEnableMotionControls=True
|
bEnableMotionControls=True
|
||||||
bFilterInputByPlatformUser=False
|
bFilterInputByPlatformUser=False
|
||||||
bEnableInputDeviceSubsystem=True
|
|
||||||
bShouldFlushPressedKeysOnViewportFocusLost=True
|
bShouldFlushPressedKeysOnViewportFocusLost=True
|
||||||
bEnableDynamicComponentInputBinding=True
|
|
||||||
bAlwaysShowTouchInterface=False
|
bAlwaysShowTouchInterface=False
|
||||||
bShowConsoleOnFourFingerTap=True
|
bShowConsoleOnFourFingerTap=True
|
||||||
bEnableGestureRecognizer=False
|
bEnableGestureRecognizer=False
|
||||||
bUseAutocorrect=False
|
bUseAutocorrect=False
|
||||||
|
bEnabledLegacyMappingDeprecationWarnings=True
|
||||||
DefaultViewportMouseCaptureMode=CapturePermanently_IncludingInitialMouseDown
|
DefaultViewportMouseCaptureMode=CapturePermanently_IncludingInitialMouseDown
|
||||||
DefaultViewportMouseLockMode=LockOnCapture
|
DefaultViewportMouseLockMode=LockOnCapture
|
||||||
FOVScale=0.011110
|
FOVScale=0.011110
|
||||||
DoubleClickTime=0.200000
|
DoubleClickTime=0.200000
|
||||||
+ActionMappings=(ActionName="Jump",bShift=False,bCtrl=False,bAlt=False,bCmd=False,Key=Gamepad_FaceButton_Bottom)
|
DeprecatedActionAndAxisNames=()
|
||||||
+ActionMappings=(ActionName="Jump",bShift=False,bCtrl=False,bAlt=False,bCmd=False,Key=SpaceBar)
|
|
||||||
+AxisMappings=(AxisName="Look Up / Down Gamepad",Scale=1.000000,Key=Gamepad_RightY)
|
|
||||||
+AxisMappings=(AxisName="Look Up / Down Mouse",Scale=-1.000000,Key=MouseY)
|
|
||||||
+AxisMappings=(AxisName="Move Forward / Backward",Scale=1.000000,Key=Gamepad_LeftY)
|
|
||||||
+AxisMappings=(AxisName="Move Forward / Backward",Scale=-1.000000,Key=S)
|
|
||||||
+AxisMappings=(AxisName="Move Forward / Backward",Scale=1.000000,Key=W)
|
|
||||||
+AxisMappings=(AxisName="Move Right / Left",Scale=-1.000000,Key=A)
|
|
||||||
+AxisMappings=(AxisName="Move Right / Left",Scale=1.000000,Key=D)
|
|
||||||
+AxisMappings=(AxisName="Move Right / Left",Scale=1.000000,Key=Gamepad_LeftX)
|
|
||||||
+AxisMappings=(AxisName="Turn Right / Left Gamepad",Scale=1.000000,Key=Gamepad_RightX)
|
|
||||||
+AxisMappings=(AxisName="Turn Right / Left Mouse",Scale=1.000000,Key=MouseX)
|
|
||||||
DefaultPlayerInputClass=/Script/EnhancedInput.EnhancedPlayerInput
|
DefaultPlayerInputClass=/Script/EnhancedInput.EnhancedPlayerInput
|
||||||
DefaultInputComponentClass=/Script/EnhancedInput.EnhancedInputComponent
|
DefaultInputComponentClass=/Script/EnhancedInput.EnhancedInputComponent
|
||||||
DefaultTouchInterface=/Engine/MobileResources/HUD/DefaultVirtualJoysticks.DefaultVirtualJoysticks
|
DefaultTouchInterface=/Engine/MobileResources/HUD/DefaultVirtualJoysticks.DefaultVirtualJoysticks
|
||||||
-ConsoleKeys=Tilde
|
-ConsoleKeys=Tilde
|
||||||
+ConsoleKeys=Tilde
|
+ConsoleKeys=Tilde
|
||||||
+ConsoleKeys=Caret
|
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
BIN
Content/Blueprints/Game/BP_ShooterGameModeBase.uasset
Normal file
BIN
Content/Blueprints/Game/BP_ShooterGameModeBase.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/API/ListFleets/WBP_FleetId.uasset
Normal file
BIN
Content/DedicatedServers/API/ListFleets/WBP_FleetId.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/API/ListFleets/WBP_ListFleetsBox.uasset
Normal file
BIN
Content/DedicatedServers/API/ListFleets/WBP_ListFleetsBox.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/APITest/BP_APITestManager.uasset
Normal file
BIN
Content/DedicatedServers/APITest/BP_APITestManager.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/APITest/UI/BP_APITestHUD.uasset
Normal file
BIN
Content/DedicatedServers/APITest/UI/BP_APITestHUD.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/APITest/UI/WBP_APITestOverlay.uasset
Normal file
BIN
Content/DedicatedServers/APITest/UI/WBP_APITestOverlay.uasset
Normal file
Binary file not shown.
BIN
Content/DedicatedServers/Data/DA_GameSessionsAPIData.uasset
Normal file
BIN
Content/DedicatedServers/Data/DA_GameSessionsAPIData.uasset
Normal file
Binary file not shown.
@@ -12,6 +12,13 @@
|
|||||||
"Engine",
|
"Engine",
|
||||||
"UMG"
|
"UMG"
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Name": "DedicatedServers",
|
||||||
|
"Type": "Runtime",
|
||||||
|
"LoadingPhase": "Default",
|
||||||
|
"ExcludelistTargets": ["Game", "Client"],
|
||||||
|
"IncludelistTargets": ["Server", "Editor"]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"Plugins": [
|
"Plugins": [
|
||||||
@@ -55,8 +62,8 @@
|
|||||||
"Enabled": false
|
"Enabled": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name": "GameLiftPlugin",
|
"Name": "GameLiftPlugin",
|
||||||
"Enabled": true
|
"Enabled": true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
41
Source/DedicatedServers/DedicatedServers.build.cs
Normal file
41
Source/DedicatedServers/DedicatedServers.build.cs
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
using UnrealBuildTool;
|
||||||
|
using System.IO;
|
||||||
|
|
||||||
|
public class DedicatedServers : ModuleRules
|
||||||
|
{
|
||||||
|
public DedicatedServers(ReadOnlyTargetRules Target) : base(Target)
|
||||||
|
{
|
||||||
|
PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs;
|
||||||
|
|
||||||
|
PublicDependencyModuleNames.AddRange(new string[]
|
||||||
|
{
|
||||||
|
"Core",
|
||||||
|
"CoreUObject",
|
||||||
|
"Engine",
|
||||||
|
"OpenSSL",
|
||||||
|
"GameplayTags",
|
||||||
|
"HTTP"
|
||||||
|
});
|
||||||
|
|
||||||
|
PrivateDependencyModuleNames.AddRange(new string[]
|
||||||
|
{
|
||||||
|
"Slate",
|
||||||
|
"SlateCore",
|
||||||
|
"UMG",
|
||||||
|
"Json",
|
||||||
|
"JsonUtilities",
|
||||||
|
});
|
||||||
|
|
||||||
|
// Adds in the plugin for GameLiftServerSDK if it is the server build.
|
||||||
|
|
||||||
|
if (Target.Type == TargetType.Server)
|
||||||
|
{
|
||||||
|
PublicDependencyModuleNames.Add("GameLiftServerSDK");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PublicDefinitions.Add("WITH_GAMELIFT=0");
|
||||||
|
}
|
||||||
|
bEnableExceptions = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
8
Source/DedicatedServers/DedicatedServers.cpp
Normal file
8
Source/DedicatedServers/DedicatedServers.cpp
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
// Copyright Epic Games, Inc. All Rights Reserved.
|
||||||
|
|
||||||
|
#include "DedicatedServers.h"
|
||||||
|
#include "Modules/ModuleManager.h"
|
||||||
|
|
||||||
|
IMPLEMENT_MODULE( FDefaultModuleImpl, DedicatedServers );
|
||||||
|
|
||||||
|
DEFINE_LOG_CATEGORY( LogDedicatedServers );
|
||||||
7
Source/DedicatedServers/DedicatedServers.h
Normal file
7
Source/DedicatedServers/DedicatedServers.h
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
// Copyright Epic Games, Inc. All Rights Reserved.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
|
||||||
|
DECLARE_LOG_CATEGORY_EXTERN(LogDedicatedServers, Log, All);
|
||||||
10
Source/DedicatedServers/Private/Data/API/APIData.cpp
Normal file
10
Source/DedicatedServers/Private/Data/API/APIData.cpp
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "Data/API/APIData.h"
|
||||||
|
|
||||||
|
FString UAPIData::GetAPIEndPoint(const FGameplayTag& APIEndPoint)
|
||||||
|
{
|
||||||
|
const FString ResourceName = Resources.FindChecked(APIEndPoint);
|
||||||
|
return InvokeUrl + "/" + Stage + "/" + ResourceName;
|
||||||
|
}
|
||||||
385
Source/DedicatedServers/Private/Game/DS_GameMode.cpp
Normal file
385
Source/DedicatedServers/Private/Game/DS_GameMode.cpp
Normal file
@@ -0,0 +1,385 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "Game/DS_GameMode.h"
|
||||||
|
|
||||||
|
#include "GameLiftClp.h"
|
||||||
|
#include "openssl/sha.h"
|
||||||
|
#include "Game/GameLift/GameLiftClpTypes.h"
|
||||||
|
|
||||||
|
#if WITH_GAMELIFT
|
||||||
|
#include "GameLiftServerSDK.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
DEFINE_LOG_CATEGORY(LogDS_GameMode);
|
||||||
|
|
||||||
|
|
||||||
|
void ADS_GameMode::BeginPlay()
|
||||||
|
{
|
||||||
|
Super::BeginPlay();
|
||||||
|
if ((GameLiftConfig.bIsAnywhereFleet && GameLiftConfig.bAllOptionsFound) ||
|
||||||
|
!GameLiftConfig.bIsAnywhereFleet)
|
||||||
|
{
|
||||||
|
InitGameLift();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, Error, TEXT("GameLift Anywhere fleet missing required options. Exiting."));
|
||||||
|
FGenericPlatformMisc::RequestExit(false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void ADS_GameMode::InitGame(const FString& MapName, const FString& Options, FString& ErrorMessage)
|
||||||
|
{
|
||||||
|
Super::InitGame(MapName, Options, ErrorMessage);
|
||||||
|
|
||||||
|
#if WITH_GAMELIFT
|
||||||
|
|
||||||
|
CachedCommandLine = FCommandLine::Get();
|
||||||
|
|
||||||
|
const FPortResult PortResult = cmdlineparser::details::GetConfiguredOrDefaultPort(CachedCommandLine, TEXT("port"));;
|
||||||
|
if (PortResult.bUsedDefaultPort)
|
||||||
|
{
|
||||||
|
UE_LOGFMT (LogDS_GameMode, Warning, "{0}", PortResult.WarningMessage);
|
||||||
|
}
|
||||||
|
|
||||||
|
GameLiftConfig.ServerPort = PortResult.Port;
|
||||||
|
if (FParse::Param(*CachedCommandLine, TEXT("glAnywhereFleet")))
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Fleet type: Anywhere");
|
||||||
|
GameLiftConfig.bIsAnywhereFleet = true;
|
||||||
|
GameLiftConfig.bAllOptionsFound = GetAnywhereFleetParameters(CachedCommandLine);
|
||||||
|
LogAnywhereFleetParameters();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Fleet type: EC2");
|
||||||
|
// TODO: EC2 configuration
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
FString ADS_GameMode::GetSHA256Hash(const FString& InString)
|
||||||
|
{
|
||||||
|
|
||||||
|
if (InString.IsEmpty())
|
||||||
|
return TEXT("e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855");
|
||||||
|
|
||||||
|
FSHA256Signature Hash;
|
||||||
|
|
||||||
|
// Use OpenSSL to compute the SHA-256 hash
|
||||||
|
|
||||||
|
FTCHARToUTF8 Utf8(InString);
|
||||||
|
const uint8* Bytes = reinterpret_cast<const uint8*>(Utf8.Get());
|
||||||
|
uint32 Length = Utf8.Length();
|
||||||
|
|
||||||
|
|
||||||
|
SHA256_CTX Sha256Context;
|
||||||
|
SHA256_Init(&Sha256Context);
|
||||||
|
SHA256_Update(&Sha256Context, Bytes,Length);
|
||||||
|
SHA256_Final(Hash.Signature, &Sha256Context);
|
||||||
|
|
||||||
|
return Hash.ToString();
|
||||||
|
}
|
||||||
|
|
||||||
|
void ADS_GameMode::InitGameLift()
|
||||||
|
{
|
||||||
|
#if WITH_GAMELIFT
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Calling InitGameLift...");
|
||||||
|
|
||||||
|
// Get the module first
|
||||||
|
FGameLiftServerSDKModule* GameLiftSdkModule = &FModuleManager::LoadModuleChecked<FGameLiftServerSDKModule>("GameLiftServerSDK");
|
||||||
|
FGameLiftGenericOutcome InitSdkOutcome;
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Initializing the GameLift Server...");
|
||||||
|
if (GameLiftConfig.bIsAnywhereFleet)
|
||||||
|
{
|
||||||
|
// Define the server parameters for an Anywhere fleet. These are not needed for a GameLift managed EC2 fleet.
|
||||||
|
FServerParameters ServerParametersForAnywhere;
|
||||||
|
|
||||||
|
uint32 PID = FPlatformProcess::GetCurrentProcessId();
|
||||||
|
FString PIDString = FString::FromInt(static_cast<int32>(PID));
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Configuring server parameters for Anywhere...");
|
||||||
|
// If AnywhereFleets are being used load the command line arguments parsed earlier.
|
||||||
|
ServerParametersForAnywhere.m_webSocketUrl = TCHAR_TO_UTF8(*GameLiftConfig.WebSocketUrlResult.Value);
|
||||||
|
ServerParametersForAnywhere.m_fleetId = TCHAR_TO_UTF8((*GameLiftConfig.FleetIdResult.Value));
|
||||||
|
ServerParametersForAnywhere.m_hostId = TCHAR_TO_UTF8(*GameLiftConfig.HostIdResult.Value);
|
||||||
|
ServerParametersForAnywhere.m_processId = PIDString;
|
||||||
|
ServerParametersForAnywhere.m_authToken = TCHAR_TO_UTF8(*GameLiftConfig.AuthTokenResult.Value);
|
||||||
|
LogServerParameters(ServerParametersForAnywhere);
|
||||||
|
|
||||||
|
// InitSDK will establish a local connection with GameLift's agent to enable further communication.
|
||||||
|
InitSdkOutcome = GameLiftSdkModule->InitSDK(ServerParametersForAnywhere);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
InitSdkOutcome = GameLiftSdkModule->InitSDK();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (InitSdkOutcome.IsSuccess())
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_GREEN);
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("GameLift InitSDK succeeded!"));
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_NONE);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_RED);
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("ERROR: InitSDK failed : ("));
|
||||||
|
FGameLiftError GameLiftError = InitSdkOutcome.GetError();
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("ERROR: %s"), *GameLiftError.m_errorMessage);
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_NONE);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ProcessParameters = MakeShared<FProcessParameters>();
|
||||||
|
//When a game session is created, Amazon GameLift Servers sends an activation request to the game server and passes along the game session object containing game properties and other settings.
|
||||||
|
//Here is where a game server should take action based on the game session object.
|
||||||
|
//Once the game server is ready to receive incoming player connections, it should invoke GameLiftServerAPI.ActivateGameSession()
|
||||||
|
// ReSharper disable once CppPassValueParameterByConstReference - not safe to do with async lambdas
|
||||||
|
ProcessParameters->OnStartGameSession.BindLambda([=](Aws::GameLift::Server::Model::GameSession InGameSession)
|
||||||
|
{
|
||||||
|
const FString GameSessionId = FString(InGameSession.GetGameSessionId());
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("GameSession Initializing: %s"), *GameSessionId);
|
||||||
|
GameLiftSdkModule->ActivateGameSession();
|
||||||
|
});
|
||||||
|
|
||||||
|
//OnProcessTerminate callback. Amazon GameLift Servers will invoke this callback before shutting down an instance hosting this game server.
|
||||||
|
//It gives this game server a chance to save its state, communicate with services, etc., before being shut down.
|
||||||
|
//In this case, we simply tell Amazon GameLift Servers we are indeed going to shut down.
|
||||||
|
ProcessParameters->OnTerminate.BindLambda([=]()
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("Game Server Process is terminating"));
|
||||||
|
// First call ProcessEnding()
|
||||||
|
FGameLiftGenericOutcome processEndingOutcome = GameLiftSdkModule->ProcessEnding();
|
||||||
|
// Then call Destroy() to free the SDK from memory
|
||||||
|
FGameLiftGenericOutcome destroyOutcome = GameLiftSdkModule->Destroy();
|
||||||
|
// Exit the process with success or failure
|
||||||
|
if (processEndingOutcome.IsSuccess() && destroyOutcome.IsSuccess()) {
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("Server process ending successfully"));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if (!processEndingOutcome.IsSuccess()) {
|
||||||
|
const FGameLiftError& error = processEndingOutcome.GetError();
|
||||||
|
UE_LOG(LogDS_GameMode, Error, TEXT("ProcessEnding() failed. Error: %s"),
|
||||||
|
error.m_errorMessage.IsEmpty() ? TEXT("Unknown error") : *error.m_errorMessage);
|
||||||
|
}
|
||||||
|
if (!destroyOutcome.IsSuccess()) {
|
||||||
|
const FGameLiftError& error = destroyOutcome.GetError();
|
||||||
|
UE_LOG(LogDS_GameMode, Error, TEXT("Destroy() failed. Error: %s"),
|
||||||
|
error.m_errorMessage.IsEmpty() ? TEXT("Unknown error") : *error.m_errorMessage);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GLog->Flush();
|
||||||
|
FGenericPlatformMisc::RequestExit(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
//This is the Health Check callback.
|
||||||
|
//Amazon GameLift Servers will invoke this callback every 60 seconds or so.
|
||||||
|
//Here, a game server might want to check the health of dependencies and such.
|
||||||
|
//Simply return true if healthy, false otherwise.
|
||||||
|
//The game server has 60 seconds to respond with its health status. Amazon GameLift Servers will default to 'false' if the game server doesn't respond in time.
|
||||||
|
//In this case, we're always healthy!
|
||||||
|
ProcessParameters->OnHealthCheck.BindLambda([]()
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("Performing Health Check"));
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
|
||||||
|
ProcessParameters->port = GameLiftConfig.ServerPort;
|
||||||
|
|
||||||
|
TArray<FString> Logfiles;
|
||||||
|
Logfiles.Add(TEXT("FPSTemplate/Saved/Log/server.log"));
|
||||||
|
ProcessParameters->logParameters = Logfiles;
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Calling Process Ready...");
|
||||||
|
FGameLiftGenericOutcome ProcessReadyOutcome = GameLiftSdkModule->ProcessReady(*ProcessParameters);
|
||||||
|
|
||||||
|
if (ProcessReadyOutcome.IsSuccess())
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_GREEN);
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("Process Ready!"));
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_NONE);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_RED);
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("ERROR: Process Ready Failed!"));
|
||||||
|
FGameLiftError ProcessReadyError = ProcessReadyOutcome.GetError();
|
||||||
|
UE_LOG(LogDS_GameMode, Log, TEXT("ERROR: %s"), *ProcessReadyError.m_errorMessage);
|
||||||
|
UE_LOG(LogDS_GameMode, SetColor, TEXT("%s"), COLOR_NONE);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "InitGameLift completed!");
|
||||||
|
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
bool ADS_GameMode::GetAnywhereFleetParameters(const FString& CommandLineString)
|
||||||
|
{
|
||||||
|
#if WITH_GAMELIFT
|
||||||
|
bool bAllAnywhereFleetParametersValid = true;
|
||||||
|
GameLiftConfig.AuthTokenResult = cmdlineparser::GetValueOfToken(CommandLineString, cmdlineparser::details::EAvailableTokens::AuthToken);
|
||||||
|
if (!GameLiftConfig.AuthTokenResult.bIsValid) bAllAnywhereFleetParametersValid = false;
|
||||||
|
|
||||||
|
GameLiftConfig.FleetIdResult = cmdlineparser::GetValueOfToken(CommandLineString, cmdlineparser::details::EAvailableTokens::FleetId);
|
||||||
|
if (!GameLiftConfig.FleetIdResult.bIsValid) bAllAnywhereFleetParametersValid = false;
|
||||||
|
|
||||||
|
GameLiftConfig.HostIdResult = cmdlineparser::GetValueOfToken(CommandLineString, cmdlineparser::details::EAvailableTokens::HostId);
|
||||||
|
if (!GameLiftConfig.HostIdResult.bIsValid) bAllAnywhereFleetParametersValid = false;
|
||||||
|
|
||||||
|
GameLiftConfig.WebSocketUrlResult = cmdlineparser::GetValueOfToken(CommandLineString, cmdlineparser::details::EAvailableTokens::WebsocketUrl);
|
||||||
|
if (!GameLiftConfig.WebSocketUrlResult.bIsValid) bAllAnywhereFleetParametersValid = false;
|
||||||
|
|
||||||
|
return bAllAnywhereFleetParametersValid;
|
||||||
|
#else
|
||||||
|
return false;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void ADS_GameMode::LogAnywhereFleetParameters()
|
||||||
|
{
|
||||||
|
// Lambda for getting the token name from token
|
||||||
|
auto GetTokenName = [](const cmdlineparser::details::FParseResult& Result) -> FString
|
||||||
|
{
|
||||||
|
return cmdlineparser::details::CLI_TOKENS.FindRef(Result.Token);
|
||||||
|
};
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Anywhere Fleet Parameters:");
|
||||||
|
if (GameLiftConfig.AuthTokenResult.bIsValid)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "AuthToken: {0}", GetValueOrHash(GameLiftConfig.AuthTokenResult.Value));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(
|
||||||
|
LogDS_GameMode,
|
||||||
|
Error,
|
||||||
|
"AuthToken: {0}",
|
||||||
|
FString::Format(
|
||||||
|
*GameLiftConfig.AuthTokenResult.ErrorMessage,
|
||||||
|
{
|
||||||
|
FStringFormatArg(GetTokenName(GameLiftConfig.AuthTokenResult)),
|
||||||
|
FStringFormatArg(GetValueOrHash(GameLiftConfig.AuthTokenResult.Value)),
|
||||||
|
}
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GameLiftConfig.FleetIdResult.bIsValid)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "FleetId: {0}", GameLiftConfig.FleetIdResult.Value);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(
|
||||||
|
LogDS_GameMode,
|
||||||
|
Error,
|
||||||
|
"FleetId: {0}",
|
||||||
|
FString::Format(
|
||||||
|
*GameLiftConfig.FleetIdResult.ErrorMessage,
|
||||||
|
{
|
||||||
|
FStringFormatArg(GetTokenName(GameLiftConfig.FleetIdResult)),
|
||||||
|
FStringFormatArg(GameLiftConfig.FleetIdResult.Value)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GameLiftConfig.HostIdResult.bIsValid)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "HostId: {0}", GameLiftConfig.HostIdResult.Value);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(
|
||||||
|
LogDS_GameMode,
|
||||||
|
Error,
|
||||||
|
"HostId: {0}",
|
||||||
|
FString::Format(
|
||||||
|
*GameLiftConfig.HostIdResult.ErrorMessage,
|
||||||
|
{
|
||||||
|
FStringFormatArg(GetTokenName(GameLiftConfig.HostIdResult)),
|
||||||
|
FStringFormatArg(GameLiftConfig.HostIdResult.Value)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GameLiftConfig.WebSocketUrlResult.bIsValid)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "WebSocketUrl: {0}", GameLiftConfig.WebSocketUrlResult.Value);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(
|
||||||
|
LogDS_GameMode,
|
||||||
|
Error,
|
||||||
|
"WebSocketUrl: {0}",
|
||||||
|
FString::Format(
|
||||||
|
*GameLiftConfig.WebSocketUrlResult.ErrorMessage,
|
||||||
|
{
|
||||||
|
FStringFormatArg(GetTokenName(GameLiftConfig.WebSocketUrlResult)),
|
||||||
|
FStringFormatArg(GameLiftConfig.WebSocketUrlResult.Value)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Server Port: {0}", GameLiftConfig.ServerPort);
|
||||||
|
|
||||||
|
if (GameLiftConfig.bAllOptionsFound)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, "Anywhere Fleet Parameters Loaded Successfully....");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Error, "Anywhere Fleet Parameters Load FAILED....");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void ADS_GameMode::LogServerParameters(const FServerParameters& InServerParameters)
|
||||||
|
{
|
||||||
|
#if WITH_GAMELIFT
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> WebSocket URL: {WebSocketUrl}", InServerParameters.m_webSocketUrl);
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Fleet ID: {FleetId}", InServerParameters.m_fleetId);
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Process ID: {ProcessId}", InServerParameters.m_processId);
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Host ID (Compute Name): {HostId}", InServerParameters.m_hostId);
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Auth Token: {AuthToken}", GetValueOrHash(InServerParameters.m_authToken));
|
||||||
|
|
||||||
|
if (!InServerParameters.m_awsRegion.IsEmpty())
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Aws Region: {AwsRegion}", InServerParameters.m_awsRegion);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!InServerParameters.m_accessKey.IsEmpty())
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Access Key: {AccessKey}", GetValueOrHash(InServerParameters.m_accessKey));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!InServerParameters.m_secretKey.IsEmpty())
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Secret Key: {SecretKey}", GetValueOrHash(InServerParameters.m_secretKey));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!InServerParameters.m_sessionToken.IsEmpty())
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDS_GameMode, Log, ">>>> Session Token: {SessionToken}", GetValueOrHash(InServerParameters.m_sessionToken));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
FString ADS_GameMode::GetValueOrHash(const FString& Value)
|
||||||
|
{
|
||||||
|
#if UE_BUILD_DEBUG || UE_BUILD_DEVELOPMENT
|
||||||
|
return Value;
|
||||||
|
#else
|
||||||
|
return TEXT("HASH:") + GetSHA256Hash(Value);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
108
Source/DedicatedServers/Private/Game/GameLift/GameLiftClp.cpp
Normal file
108
Source/DedicatedServers/Private/Game/GameLift/GameLiftClp.cpp
Normal file
@@ -0,0 +1,108 @@
|
|||||||
|
#include "GameLiftClp.h"
|
||||||
|
|
||||||
|
namespace cmdlineparser
|
||||||
|
{
|
||||||
|
FPortResult cmdlineparser::GetConfiguredOrDefaultPort(const FString& Token)
|
||||||
|
{
|
||||||
|
return details::GetConfiguredOrDefaultPort(FCommandLine::Get(), Token);
|
||||||
|
}
|
||||||
|
|
||||||
|
FPortResult cmdlineparser::GetConfiguredOrDefaultPort(const FString& CommandLine, const FString& Token)
|
||||||
|
{
|
||||||
|
return details::GetConfiguredOrDefaultPort(CommandLine, Token);
|
||||||
|
}
|
||||||
|
|
||||||
|
details::FParseResult cmdlineparser::GetValueOfToken(const FString& CommandLine, const details::EAvailableTokens Token)
|
||||||
|
{
|
||||||
|
details::FParseResult Result;
|
||||||
|
FString ValueOfToken;
|
||||||
|
Result.Token = Token;
|
||||||
|
|
||||||
|
ensure(Token != details::EAvailableTokens::Unknown);
|
||||||
|
|
||||||
|
const bool bTokenFound = FParse::Value(
|
||||||
|
*CommandLine,
|
||||||
|
*details::EnsureEndsWith(details::CLI_TOKENS.FindRef(Token), TEXT("=")),
|
||||||
|
ValueOfToken
|
||||||
|
);
|
||||||
|
|
||||||
|
if (!bTokenFound)
|
||||||
|
{
|
||||||
|
Result.Value = FString();
|
||||||
|
Result.ErrorCode = details::EErrorCodes::TokenNotFound;
|
||||||
|
Result.bIsValid = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (ValueOfToken.IsEmpty())
|
||||||
|
{
|
||||||
|
Result.Value = FString();
|
||||||
|
Result.ErrorCode = details::EErrorCodes::ValueEmpty;
|
||||||
|
Result.bIsValid = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (details::DoesRegExMatch(ValueOfToken, details::REGEX_PATTERNS.FindRef(Token)))
|
||||||
|
{
|
||||||
|
Result.ErrorCode = details::EErrorCodes::NoError;
|
||||||
|
Result.bIsValid = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Result.ErrorCode = details::EErrorCodes::FailedValidation;
|
||||||
|
Result.bIsValid = false;
|
||||||
|
}
|
||||||
|
Result.Value = ValueOfToken;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ensure(Result.ErrorCode < details::EErrorCodes::MaxCode);
|
||||||
|
FString ErrorMessage = details::ERROR_MESSAGES.FindRef(Result.ErrorCode);
|
||||||
|
FString TokenName = details::CLI_TOKENS.FindRef(Result.Token);
|
||||||
|
FString Value = Result.Value;
|
||||||
|
Result.ErrorMessage = ErrorMessage;
|
||||||
|
|
||||||
|
return Result;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// cmdlineparser::Details namespace
|
||||||
|
namespace details
|
||||||
|
{
|
||||||
|
FString details::EnsureEndsWith(const FString& Token, const TCHAR* Suffix)
|
||||||
|
{
|
||||||
|
return Token.EndsWith(Suffix) ? Token : Token + Suffix;
|
||||||
|
}
|
||||||
|
|
||||||
|
FPortResult details::GetConfiguredOrDefaultPort(const FString& CommandLine, const FString& Token)
|
||||||
|
{
|
||||||
|
FPortResult PortResult;
|
||||||
|
PortResult.Port = FURL::UrlConfig.DefaultPort;
|
||||||
|
|
||||||
|
if (int32 CliPort; FParse::Value(*CommandLine, *EnsureEndsWith(Token, TEXT("=")), CliPort))
|
||||||
|
{
|
||||||
|
if (CliPort >= details::MIN_PORT && CliPort <= details::MAX_PORT)
|
||||||
|
{
|
||||||
|
PortResult.Port = CliPort;
|
||||||
|
PortResult.bUsedDefaultPort = false;
|
||||||
|
PortResult.WarningMessage = FString();
|
||||||
|
return PortResult;
|
||||||
|
}
|
||||||
|
PortResult.bUsedDefaultPort = true;
|
||||||
|
PortResult.WarningMessage = FString::Printf(TEXT("Command Line Option for Port is out of ranged... Using Default Port %d"), PortResult.Port);
|
||||||
|
return PortResult;
|
||||||
|
|
||||||
|
}
|
||||||
|
PortResult.bUsedDefaultPort = true;
|
||||||
|
PortResult.WarningMessage = FString::Printf(TEXT("Command Line Option for Port not found... Using Default Port %d"), PortResult.Port);
|
||||||
|
return PortResult;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool details::DoesRegExMatch(const FString& Text, const FString& Pattern)
|
||||||
|
{
|
||||||
|
const FRegexPattern RegexPattern(Pattern);
|
||||||
|
FRegexMatcher Matcher(RegexPattern, Text);
|
||||||
|
return Matcher.FindNext();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
#include "GameplayTags/DedicatedServerTags.h"
|
||||||
|
|
||||||
|
namespace DedicatedServersTags
|
||||||
|
{
|
||||||
|
namespace GameSessionsAPI
|
||||||
|
{
|
||||||
|
UE_DEFINE_GAMEPLAY_TAG_COMMENT(ListFleets, "DedicatedServersTags.GameSessionsAPI.ListFleets", "List Fleets resource on the GameSessions API")
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/API/ListFleets/FleetId.h"
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/API/ListFleets/ListFleetsBox.h"
|
||||||
18
Source/DedicatedServers/Private/UI/APITest/APITestHUD.cpp
Normal file
18
Source/DedicatedServers/Private/UI/APITest/APITestHUD.cpp
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/APITest/APITestHUD.h"
|
||||||
|
|
||||||
|
#include "UI/APITest/APITestOverlay.h"
|
||||||
|
|
||||||
|
void AAPITestHUD::BeginPlay()
|
||||||
|
{
|
||||||
|
Super::BeginPlay();
|
||||||
|
|
||||||
|
APlayerController* PlayerController = GetOwningPlayerController();
|
||||||
|
if (IsValid(PlayerController) && APITestOverlayClass)
|
||||||
|
{
|
||||||
|
APITestOverlay = CreateWidget<UAPITestOverlay>(PlayerController, APITestOverlayClass);
|
||||||
|
APITestOverlay->AddToViewport();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/APITest/APITestManager.h"
|
||||||
|
#include "HttpModule.h"
|
||||||
|
#include "JsonObjectConverter.h"
|
||||||
|
#include "Data/API/APIData.h"
|
||||||
|
#include "GameplayTags/DedicatedServerTags.h"
|
||||||
|
#include "Interfaces/IHttpResponse.h"
|
||||||
|
#include "UI/HTTP/HTTPRequestTypes.h"
|
||||||
|
|
||||||
|
|
||||||
|
void UAPITestManager::ListFleets()
|
||||||
|
{
|
||||||
|
check(APIData);
|
||||||
|
|
||||||
|
TSharedPtr<IHttpRequest> Request = FHttpModule::Get().CreateRequest();
|
||||||
|
Request->OnProcessRequestComplete().BindUObject(this, &UAPITestManager::ListFleets_Response);
|
||||||
|
|
||||||
|
const FString APIUrl = APIData->GetAPIEndPoint(DedicatedServersTags::GameSessionsAPI::ListFleets);
|
||||||
|
|
||||||
|
Request->SetURL(APIUrl);
|
||||||
|
Request->SetVerb("GET");
|
||||||
|
Request->SetHeader("Content-Type", "application/json");
|
||||||
|
Request->ProcessRequest();
|
||||||
|
}
|
||||||
|
|
||||||
|
void UAPITestManager::ListFleets_Response(FHttpRequestPtr Request, FHttpResponsePtr Response, bool bWasSuccessful)
|
||||||
|
{
|
||||||
|
TSharedPtr<FJsonObject> JsonObject;
|
||||||
|
TSharedRef<TJsonReader<>> JsonReader = TJsonReaderFactory<>::Create(Response->GetContentAsString());
|
||||||
|
|
||||||
|
if (FJsonSerializer::Deserialize(JsonReader, JsonObject))
|
||||||
|
{
|
||||||
|
if (ContainsErrors(JsonObject))
|
||||||
|
{
|
||||||
|
OnListFleetsResponseReceived.Broadcast(FDSListFleetsResponse(), false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
DumpMetadata(JsonObject);
|
||||||
|
|
||||||
|
FDSListFleetsResponse ListFleetsResponse;
|
||||||
|
FJsonObjectConverter::JsonObjectToUStruct(JsonObject.ToSharedRef(), &ListFleetsResponse);
|
||||||
|
OnListFleetsResponseReceived.Broadcast(ListFleetsResponse, true);
|
||||||
|
ListFleetsResponse.Dump();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,59 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/APITest/APITestOverlay.h"
|
||||||
|
|
||||||
|
#include "Blueprint/WidgetLayoutLibrary.h"
|
||||||
|
#include "Components/Button.h"
|
||||||
|
#include "Components/ScrollBox.h"
|
||||||
|
#include "Components/TextBlock.h"
|
||||||
|
#include "UI/API/ListFleets/FleetId.h"
|
||||||
|
#include "UI/API/ListFleets/ListFleetsBox.h"
|
||||||
|
#include "UI/APITest/APITestManager.h"
|
||||||
|
#include "UI/HTTP/HTTPRequestTypes.h"
|
||||||
|
|
||||||
|
void UAPITestOverlay::NativeConstruct()
|
||||||
|
{
|
||||||
|
Super::NativeConstruct();
|
||||||
|
|
||||||
|
check(APITestManagerClass);
|
||||||
|
APITestManager = NewObject<UAPITestManager>(this, APITestManagerClass);
|
||||||
|
|
||||||
|
check(ListFleetsBox)
|
||||||
|
check(ListFleetsBox->Button_ListFleets)
|
||||||
|
ListFleetsBox->Button_ListFleets->OnClicked.AddDynamic(this, &UAPITestOverlay::ListFleetsButtonClicked);
|
||||||
|
}
|
||||||
|
|
||||||
|
void UAPITestOverlay::ListFleetsButtonClicked()
|
||||||
|
{
|
||||||
|
check (APITestManager)
|
||||||
|
APITestManager->OnListFleetsResponseReceived.AddDynamic(this, &UAPITestOverlay::OnListFleetsResponseReceived);
|
||||||
|
APITestManager->ListFleets();
|
||||||
|
ListFleetsBox->Button_ListFleets->SetIsEnabled(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
void UAPITestOverlay::OnListFleetsResponseReceived(const FDSListFleetsResponse& ListFleetsResponse, bool bWasSuccessful)
|
||||||
|
{
|
||||||
|
if (APITestManager->OnListFleetsResponseReceived.IsAlreadyBound(this, &UAPITestOverlay::OnListFleetsResponseReceived))
|
||||||
|
{
|
||||||
|
APITestManager->OnListFleetsResponseReceived.RemoveDynamic(this, &UAPITestOverlay::OnListFleetsResponseReceived);
|
||||||
|
}
|
||||||
|
ListFleetsBox->ScrollBox_ListFleets->ClearChildren();
|
||||||
|
check(FleetIdWidgetClass);
|
||||||
|
if (bWasSuccessful)
|
||||||
|
{
|
||||||
|
for (const FString& FleetId : ListFleetsResponse.FleetIds)
|
||||||
|
{
|
||||||
|
UFleetId* FleetIdWidget = CreateWidget<UFleetId>(this, FleetIdWidgetClass);
|
||||||
|
FleetIdWidget->TextBlock_FleetId->SetText(FText::FromString(FleetId));
|
||||||
|
ListFleetsBox->ScrollBox_ListFleets->AddChild(FleetIdWidget);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UFleetId* FleetIdWidget = CreateWidget<UFleetId>(this, FleetIdWidgetClass);
|
||||||
|
FleetIdWidget->TextBlock_FleetId->SetText(FText::FromString("Something went wrong!"));
|
||||||
|
ListFleetsBox->ScrollBox_ListFleets->AddChild(FleetIdWidget);
|
||||||
|
}
|
||||||
|
ListFleetsBox->Button_ListFleets->SetIsEnabled(true);
|
||||||
|
}
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "UI/HTTP/HTTPRequestManager.h"
|
||||||
|
|
||||||
|
#include "JsonObjectConverter.h"
|
||||||
|
#include "DedicatedServers/DedicatedServers.h"
|
||||||
|
#include "UI/HTTP/HTTPRequestTypes.h"
|
||||||
|
|
||||||
|
bool UHTTPRequestManager::ContainsErrors(TSharedPtr<FJsonObject> JsonObject, bool bLogErrors)
|
||||||
|
{
|
||||||
|
if (JsonObject->HasField(TEXT("errorType")) || JsonObject->HasField(TEXT("errorMessage")))
|
||||||
|
{
|
||||||
|
FString ErrorType = JsonObject->HasField(TEXT("errorType")) ? JsonObject->GetStringField(TEXT("errorType")) : FString("Unknown Error");
|
||||||
|
FString ErrorMessage = JsonObject->HasField(TEXT("errorMessage")) ? JsonObject->GetStringField(TEXT("errorMessage")) : FString("Unknown Error Message");
|
||||||
|
|
||||||
|
if (bLogErrors)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Error, "Error Type: {ErrorType}", ErrorType);
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Error, "Error Message: {ErrorMessage}", ErrorMessage);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (JsonObject->HasField(TEXT("$fault")))
|
||||||
|
{
|
||||||
|
FString ErrorType = JsonObject->HasField(TEXT("name")) ? JsonObject->GetStringField(TEXT("name")) : FString("Unknown Error");
|
||||||
|
|
||||||
|
if (bLogErrors)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Error, "Error Type: {ErrorType}", ErrorType);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void UHTTPRequestManager::DumpMetadata(TSharedPtr<FJsonObject> JsonObject)
|
||||||
|
{
|
||||||
|
if (JsonObject->HasField(TEXT("$metadata")))
|
||||||
|
{
|
||||||
|
TSharedPtr<FJsonObject> MetaDataJsonObject = JsonObject->GetObjectField(TEXT("$metadata"));
|
||||||
|
FDSMetaData DSMetaData;
|
||||||
|
FJsonObjectConverter::JsonObjectToUStruct(MetaDataJsonObject.ToSharedRef(), &DSMetaData);
|
||||||
|
|
||||||
|
DSMetaData.Dump();
|
||||||
|
}
|
||||||
|
}
|
||||||
26
Source/DedicatedServers/Private/UI/HTTP/HTTPRequestTypes.cpp
Normal file
26
Source/DedicatedServers/Private/UI/HTTP/HTTPRequestTypes.cpp
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
#include "UI/HTTP/HTTPRequestTypes.h"
|
||||||
|
#include "DedicatedServers/DedicatedServers.h"
|
||||||
|
|
||||||
|
void FDSMetaData::Dump() const
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "MetaData:");
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "httpStatusCode: {httpStatusCode}", httpStatusCode);
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "requestId: {requestId}", requestId);
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "attempts: {attempts}", attempts);
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "totalRetryDelay: {totalRetryDelay}", totalRetryDelay);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FDSListFleetsResponse::Dump() const
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "ListFleetsResponse:");
|
||||||
|
|
||||||
|
for (const FString& FleetId : FleetIds)
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "FleetId: {FleetId}", *FleetId);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!NextToken.IsEmpty())
|
||||||
|
{
|
||||||
|
UE_LOGFMT(LogDedicatedServers, Log, "NextToken: {NextToken}", NextToken);
|
||||||
|
}
|
||||||
|
}
|
||||||
38
Source/DedicatedServers/Public/Data/API/APIData.h
Normal file
38
Source/DedicatedServers/Public/Data/API/APIData.h
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "Engine/DataAsset.h"
|
||||||
|
#include "GameplayTags/DedicatedServerTags.h"
|
||||||
|
#include "APIData.generated.h"
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API UAPIData : public UDataAsset
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
FString GetAPIEndPoint(const FGameplayTag& APIEndPoint);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
// Name of this API - for labeling in the Data Asset; This is nto used by any code.
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
FString Name;
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
FString InvokeUrl;
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
FString Stage;
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
TMap<FGameplayTag, FString> Resources;
|
||||||
|
|
||||||
|
|
||||||
|
};
|
||||||
55
Source/DedicatedServers/Public/Game/DS_GameMode.h
Normal file
55
Source/DedicatedServers/Public/Game/DS_GameMode.h
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
struct FServerParameters;
|
||||||
|
struct FProcessParameters;
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "GameFramework/GameMode.h"
|
||||||
|
#include "Game/GameLift/GameLiftClpTypes.h"
|
||||||
|
#include "DS_GameMode.generated.h"
|
||||||
|
|
||||||
|
DECLARE_LOG_CATEGORY_EXTERN(LogDS_GameMode, Log, All);
|
||||||
|
|
||||||
|
struct FGameLiftConfig
|
||||||
|
{
|
||||||
|
bool bIsAnywhereFleet = false;
|
||||||
|
bool bAllOptionsFound = false;
|
||||||
|
|
||||||
|
int32 ServerPort = 7777;
|
||||||
|
|
||||||
|
cmdlineparser::details::FParseResult AuthTokenResult;
|
||||||
|
cmdlineparser::details::FParseResult FleetIdResult;
|
||||||
|
cmdlineparser::details::FParseResult HostIdResult;
|
||||||
|
cmdlineparser::details::FParseResult WebSocketUrlResult;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API ADS_GameMode : public AGameMode
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void BeginPlay() override;
|
||||||
|
|
||||||
|
virtual void InitGame(const FString& MapName, const FString& Options, FString& ErrorMessage) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
FGameLiftConfig GameLiftConfig;
|
||||||
|
FString CachedCommandLine;
|
||||||
|
|
||||||
|
static FString GetSHA256Hash(const FString& InString);
|
||||||
|
void InitGameLift();
|
||||||
|
|
||||||
|
bool GetAnywhereFleetParameters(const FString& CommandLineString);
|
||||||
|
void LogAnywhereFleetParameters();
|
||||||
|
|
||||||
|
TSharedPtr<FProcessParameters> ProcessParameters;
|
||||||
|
static void LogServerParameters(const FServerParameters& InServerParameters);
|
||||||
|
|
||||||
|
static FString GetValueOrHash(const FString& Value);
|
||||||
|
};
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
namespace cmdlineparser::details
|
||||||
|
{
|
||||||
|
enum EAvailableTokens
|
||||||
|
{
|
||||||
|
Unknown = 0,
|
||||||
|
AuthToken,
|
||||||
|
HostId,
|
||||||
|
FleetId,
|
||||||
|
WebsocketUrl,
|
||||||
|
MaxToken
|
||||||
|
};
|
||||||
|
|
||||||
|
enum EErrorCodes
|
||||||
|
{
|
||||||
|
NoError,
|
||||||
|
TokenNotFound,
|
||||||
|
ValueEmpty,
|
||||||
|
FailedValidation,
|
||||||
|
MaxCode
|
||||||
|
};
|
||||||
|
|
||||||
|
inline static const TMap<EErrorCodes, FString>& ERROR_MESSAGES = []() ->
|
||||||
|
const TMap<EErrorCodes, FString>&
|
||||||
|
{
|
||||||
|
static TMap<EErrorCodes, FString> Error_Messages =
|
||||||
|
{
|
||||||
|
{NoError,TEXT("VALID: {0}: {1}") },
|
||||||
|
{FailedValidation,TEXT("VALIDATION FAILED: [-{0}=] found.... Value: [{1}]") },
|
||||||
|
{TokenNotFound,TEXT("INVALID TOKEN: [-{0}=] not found in command line arguments") },
|
||||||
|
{ValueEmpty,TEXT("EMPTY VALUE: [-{0}=] found. No value assigned") },
|
||||||
|
|
||||||
|
};
|
||||||
|
return Error_Messages;
|
||||||
|
}();
|
||||||
|
|
||||||
|
inline static const TMap<EAvailableTokens, FString>& CLI_TOKENS = []() ->
|
||||||
|
const TMap<EAvailableTokens, FString>&
|
||||||
|
{
|
||||||
|
static TMap<EAvailableTokens, FString> Cli_Tokens =
|
||||||
|
{
|
||||||
|
{AuthToken, TEXT("authtoken") },
|
||||||
|
{FleetId, TEXT("fleetid") },
|
||||||
|
{HostId, TEXT("hostid") },
|
||||||
|
{Unknown, TEXT("unknown") },
|
||||||
|
{WebsocketUrl, TEXT("websocketurl") }
|
||||||
|
};
|
||||||
|
return Cli_Tokens;
|
||||||
|
}();
|
||||||
|
|
||||||
|
inline static const TMap<EAvailableTokens, FString>& REGEX_PATTERNS = []() ->
|
||||||
|
const TMap<EAvailableTokens, FString>&
|
||||||
|
{
|
||||||
|
static TMap<EAvailableTokens, FString> Regex_Patterns =
|
||||||
|
{
|
||||||
|
{Unknown,TEXT(".*") },
|
||||||
|
{AuthToken,TEXT("^[a-zA-Z0-9\\-]+$") },
|
||||||
|
{HostId,TEXT("^[a-zA-Z0-9][a-zA-Z0-9\\-]{0,62}[a-zA-Z0-9]?$") },
|
||||||
|
{FleetId,TEXT("^[a-z]*fleet-[a-zA-Z0-9\\-]+$|^arn:.*:[a-z]*fleet\\/[a-z]*fleet-[a-zA-Z0-9\\-]+$") },
|
||||||
|
{WebsocketUrl,TEXT("^wss://[a-z0-9-]+(\\.[a-z0-9-]+)*\\.api\\.amazongamelift\\.com(:[0-9]+)?/?$") },
|
||||||
|
};
|
||||||
|
return Regex_Patterns;
|
||||||
|
}();
|
||||||
|
|
||||||
|
// extern const TMap<EErrorCodes, FString>& ERROR_MESSAGES;
|
||||||
|
// extern const TMap<EAvailableTokens, FString>& CLI_TOKENS;
|
||||||
|
// extern const TMap<EAvailableTokens, FString>& REGEX_PATTERNS;
|
||||||
|
|
||||||
|
struct FParseResult
|
||||||
|
{
|
||||||
|
EAvailableTokens Token = EAvailableTokens::Unknown;
|
||||||
|
FString Value = FString();
|
||||||
|
bool bIsValid = false;
|
||||||
|
EErrorCodes ErrorCode = EErrorCodes::TokenNotFound;
|
||||||
|
FString ErrorMessage = FString();
|
||||||
|
|
||||||
|
};
|
||||||
|
}
|
||||||
29
Source/DedicatedServers/Public/GameLiftClp.h
Normal file
29
Source/DedicatedServers/Public/GameLiftClp.h
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
#pragma once
|
||||||
|
#include "Game/GameLift/GameLiftClpTypes.h"
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
|
||||||
|
struct FPortResult
|
||||||
|
{
|
||||||
|
int32 Port;
|
||||||
|
bool bUsedDefaultPort;
|
||||||
|
FString WarningMessage;
|
||||||
|
};
|
||||||
|
|
||||||
|
namespace cmdlineparser
|
||||||
|
{
|
||||||
|
FPortResult GetConfiguredOrDefaultPort(const FString& Token = TEXT("port="));
|
||||||
|
FPortResult GetConfiguredOrDefaultPort(const FString& CommandLine, const FString& Token = TEXT("port="));
|
||||||
|
|
||||||
|
details::FParseResult GetValueOfToken(const FString& CommandLine, const details::EAvailableTokens Token);
|
||||||
|
|
||||||
|
namespace details
|
||||||
|
{
|
||||||
|
inline static constexpr int32 MIN_PORT = 1024;
|
||||||
|
inline static constexpr int32 MAX_PORT = 65535;
|
||||||
|
inline const TCHAR* DEFAULT_PORT_TOKEN = TEXT("port=");
|
||||||
|
|
||||||
|
FString EnsureEndsWith(const FString& Token, const TCHAR* Suffix);
|
||||||
|
FPortResult GetConfiguredOrDefaultPort(const FString& CommandLine, const FString& Token);
|
||||||
|
bool DoesRegExMatch(const FString& Text, const FString& Pattern);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "NativeGameplayTags.h"
|
||||||
|
|
||||||
|
namespace DedicatedServersTags
|
||||||
|
{
|
||||||
|
namespace GameSessionsAPI
|
||||||
|
{
|
||||||
|
UE_DECLARE_GAMEPLAY_TAG_EXTERN(ListFleets);
|
||||||
|
}
|
||||||
|
}
|
||||||
22
Source/DedicatedServers/Public/UI/API/ListFleets/FleetId.h
Normal file
22
Source/DedicatedServers/Public/UI/API/ListFleets/FleetId.h
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "Blueprint/UserWidget.h"
|
||||||
|
#include "FleetId.generated.h"
|
||||||
|
|
||||||
|
class UTextBlock;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API UFleetId : public UUserWidget
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
UPROPERTY(meta = (BindWidget))
|
||||||
|
TObjectPtr<UTextBlock> TextBlock_FleetId;
|
||||||
|
};
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "Blueprint/UserWidget.h"
|
||||||
|
#include "ListFleetsBox.generated.h"
|
||||||
|
|
||||||
|
class UButton;
|
||||||
|
class UScrollBox;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API UListFleetsBox : public UUserWidget
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
UPROPERTY(meta = (BindWidget))
|
||||||
|
TObjectPtr<UScrollBox> ScrollBox_ListFleets;
|
||||||
|
|
||||||
|
UPROPERTY(meta = (BindWidget))
|
||||||
|
TObjectPtr<UButton> Button_ListFleets;
|
||||||
|
|
||||||
|
};
|
||||||
31
Source/DedicatedServers/Public/UI/APITest/APITestHUD.h
Normal file
31
Source/DedicatedServers/Public/UI/APITest/APITestHUD.h
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
class UAPITestOverlay;
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "GameFramework/HUD.h"
|
||||||
|
#include "APITestHUD.generated.h"
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API AAPITestHUD : public AHUD
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
TSubclassOf<UAPITestOverlay> APITestOverlayClass;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
virtual void BeginPlay() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
UPROPERTY()
|
||||||
|
TObjectPtr<UAPITestOverlay> APITestOverlay;
|
||||||
|
};
|
||||||
30
Source/DedicatedServers/Public/UI/APITest/APITestManager.h
Normal file
30
Source/DedicatedServers/Public/UI/APITest/APITestManager.h
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "Interfaces/IHttpRequest.h"
|
||||||
|
#include "UI/HTTP/HTTPRequestManager.h"
|
||||||
|
#include "APITestManager.generated.h"
|
||||||
|
|
||||||
|
DECLARE_DYNAMIC_MULTICAST_DELEGATE_TwoParams(FOnListFleetsResponseReceived, const FDSListFleetsResponse&, ListFleetsResponse, bool, bWasSuccessful);
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API UAPITestManager : public UHTTPRequestManager
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
UFUNCTION()
|
||||||
|
void ListFleets();
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
FOnListFleetsResponseReceived OnListFleetsResponseReceived;
|
||||||
|
|
||||||
|
void ListFleets_Response(FHttpRequestPtr Request, FHttpResponsePtr Response, bool bWasSuccessful);
|
||||||
|
};
|
||||||
48
Source/DedicatedServers/Public/UI/APITest/APITestOverlay.h
Normal file
48
Source/DedicatedServers/Public/UI/APITest/APITestOverlay.h
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "Blueprint/UserWidget.h"
|
||||||
|
#include "APITestOverlay.generated.h"
|
||||||
|
|
||||||
|
class UListFleetsBox;
|
||||||
|
class UAPITestManager;
|
||||||
|
struct FDSListFleetsResponse;
|
||||||
|
class UFleetId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class DEDICATEDSERVERS_API UAPITestOverlay : public UUserWidget
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
TSubclassOf<UAPITestManager> APITestManagerClass;
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
TSubclassOf<UFleetId> FleetIdWidgetClass;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
virtual void NativeConstruct() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
UPROPERTY(meta = (BindWidget))
|
||||||
|
TObjectPtr<UListFleetsBox> ListFleetsBox = nullptr;
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
TObjectPtr<UAPITestManager> APITestManager;
|
||||||
|
|
||||||
|
UFUNCTION()
|
||||||
|
void ListFleetsButtonClicked();
|
||||||
|
|
||||||
|
UFUNCTION()
|
||||||
|
void OnListFleetsResponseReceived(const FDSListFleetsResponse& ListFleetsResponse, bool bWasSuccessful);
|
||||||
|
|
||||||
|
};
|
||||||
27
Source/DedicatedServers/Public/UI/HTTP/HTTPRequestManager.h
Normal file
27
Source/DedicatedServers/Public/UI/HTTP/HTTPRequestManager.h
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "UObject/Object.h"
|
||||||
|
#include "HTTPRequestManager.generated.h"
|
||||||
|
|
||||||
|
class UAPIData;
|
||||||
|
class FJsonObject;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS(Blueprintable)
|
||||||
|
class DEDICATEDSERVERS_API UHTTPRequestManager : public UObject
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
UPROPERTY(EditDefaultsOnly)
|
||||||
|
TObjectPtr<UAPIData> APIData;
|
||||||
|
|
||||||
|
bool ContainsErrors(TSharedPtr<FJsonObject> JsonObject, bool bLogErrors = true);
|
||||||
|
void DumpMetadata(TSharedPtr<FJsonObject> JsonObject);
|
||||||
|
};
|
||||||
37
Source/DedicatedServers/Public/UI/HTTP/HTTPRequestTypes.h
Normal file
37
Source/DedicatedServers/Public/UI/HTTP/HTTPRequestTypes.h
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "HTTPRequestTypes.generated.h"
|
||||||
|
|
||||||
|
USTRUCT()
|
||||||
|
struct FDSMetaData
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
int32 httpStatusCode{};
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
FString requestId{};
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
int32 attempts{};
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
double totalRetryDelay{};
|
||||||
|
|
||||||
|
void Dump() const;
|
||||||
|
};
|
||||||
|
|
||||||
|
USTRUCT()
|
||||||
|
struct FDSListFleetsResponse
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
TArray<FString> FleetIds;
|
||||||
|
|
||||||
|
UPROPERTY()
|
||||||
|
FString NextToken;
|
||||||
|
|
||||||
|
void Dump() const;
|
||||||
|
};
|
||||||
@@ -1,6 +1,8 @@
|
|||||||
// Copyright Epic Games, Inc. All Rights Reserved.
|
// Copyright Epic Games, Inc. All Rights Reserved.
|
||||||
|
|
||||||
|
using System.IO;
|
||||||
using UnrealBuildTool;
|
using UnrealBuildTool;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
public class FPSTemplate : ModuleRules
|
public class FPSTemplate : ModuleRules
|
||||||
{
|
{
|
||||||
@@ -8,21 +10,25 @@ public class FPSTemplate : ModuleRules
|
|||||||
{
|
{
|
||||||
PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs;
|
PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs;
|
||||||
|
|
||||||
PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "EnhancedInput", "PhysicsCore" });
|
PublicDependencyModuleNames.AddRange(new string[]
|
||||||
|
|
||||||
PrivateDependencyModuleNames.AddRange(new string[] { "GameplayTags", "Slate", "SlateCore" });
|
|
||||||
|
|
||||||
// Adds in the plugin for GameLiftServerSDK if it is the server build.
|
|
||||||
|
|
||||||
if (Target.Type == TargetType.Server)
|
|
||||||
{
|
{
|
||||||
PublicDependencyModuleNames.Add("GameLiftServerSDK");
|
"Core",
|
||||||
}
|
"CoreUObject",
|
||||||
else
|
"Engine",
|
||||||
|
"InputCore",
|
||||||
|
"EnhancedInput",
|
||||||
|
"PhysicsCore",
|
||||||
|
"OpenSSL",
|
||||||
|
"DedicatedServers"
|
||||||
|
});
|
||||||
|
|
||||||
|
PrivateDependencyModuleNames.AddRange(new string[]
|
||||||
{
|
{
|
||||||
PublicDefinitions.Add("WITH_GAMELIFT=0");
|
"GameplayTags",
|
||||||
}
|
"Slate",
|
||||||
bEnableExceptions = true;
|
"SlateCore",
|
||||||
|
"OpenSSL",
|
||||||
|
});
|
||||||
|
|
||||||
// Uncomment if you are using Slate UI
|
// Uncomment if you are using Slate UI
|
||||||
// PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" });
|
// PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" });
|
||||||
|
|||||||
@@ -1,318 +0,0 @@
|
|||||||
// Fill out your copyright notice in the Description page of Project Settings.
|
|
||||||
|
|
||||||
|
|
||||||
#include "Game/ShooterGameMode.h"
|
|
||||||
#include "Logging/LogMacros.h"
|
|
||||||
#include "Logging/StructuredLog.h"
|
|
||||||
|
|
||||||
#if WITH_GAMELIFT
|
|
||||||
#include "GameLiftServerSDK.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
DEFINE_LOG_CATEGORY(LogShooterGameMode)
|
|
||||||
|
|
||||||
namespace GameLiftValidators {
|
|
||||||
const FRegexPattern FleetIdPattern(TEXT("^[a-z]*fleet-[a-zA-Z0-9\\-]+$"));
|
|
||||||
const int32 FleetIdLengthMin = 1;
|
|
||||||
const int32 FleetIdLengthMax = 128;
|
|
||||||
const FString ServerRegionPattern(TEXT("^[a-z]{2}-[a-z]+-[0-9]$"));
|
|
||||||
const int32 ServerRegionLengthMin = 3;
|
|
||||||
const int32 ServerRegionLengthMax = 16;
|
|
||||||
const FString WebSocketUrlPattern(TEXT("^(ws|wss):\\/\\/([0-9a-zA-Z.-]+)(:([1-9][0-9]{0,4}))?(\\/.*)?$"));
|
|
||||||
const int32 WebSocketUrlLengthMin = 1;
|
|
||||||
const int32 WebSocketUrlLengthMax = 128;
|
|
||||||
const FString AuthTokenPattern(TEXT("^[A-Za-z0-9+/=]+$"));
|
|
||||||
const int32 AuthTokenLengthMin = 20;
|
|
||||||
const int32 AuthTokenLengthMax = 2048;
|
|
||||||
const FString HostIdPattern(TEXT("^[a-z]*host-[a-zA-Z0-9\\-]+$"));
|
|
||||||
const int32 HostIdLengthMin = 1;
|
|
||||||
const int32 HostIdLengthMax = 128;
|
|
||||||
const int32 ServerPortMin = 1026;
|
|
||||||
const int32 ServerPortMax = 60000;
|
|
||||||
const int32 WebSocketPortMin = 1;
|
|
||||||
const int32 WebSocketPortMax = 60000;
|
|
||||||
|
|
||||||
bool IsStringValid(const FString& Value, const FRegexPattern* OptionalPattern, const int32 Min, const int32 Max)
|
|
||||||
{
|
|
||||||
if (Value.IsEmpty()) return false;
|
|
||||||
|
|
||||||
if (OptionalPattern)
|
|
||||||
{
|
|
||||||
return FRegexMatcher(*OptionalPattern, Value).FindNext() &&
|
|
||||||
Value.Len() >= Min &&
|
|
||||||
Value.Len() <= Max;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return Value.Len() >= Min && Value.Len() <= Max;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
bool IsNumberValid(const int32 Value, const int32 Min, const int32 Max)
|
|
||||||
{
|
|
||||||
return Value >= Min && Value <= Max;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
AShooterGameMode::AShooterGameMode()
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Initializing ShooterGameMode..."));
|
|
||||||
}
|
|
||||||
|
|
||||||
void AShooterGameMode::BeginPlay()
|
|
||||||
{
|
|
||||||
Super::BeginPlay();
|
|
||||||
|
|
||||||
#if WITH_GAMELIFT
|
|
||||||
InitGameLift();
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
void AShooterGameMode::InitGame(const FString& MapName, const FString& Options, FString& ErrorMessage)
|
|
||||||
{
|
|
||||||
Super::InitGame(MapName, Options, ErrorMessage);
|
|
||||||
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("[%s] Parsing CLI"), *FDateTime::UtcNow().ToString(TEXT("%Y%m%d-%H%M%S")));
|
|
||||||
CachedCommandLine = FCommandLine::Get();
|
|
||||||
|
|
||||||
// Parsing of Command Line
|
|
||||||
GameLiftConfig.bDebugMode = FParse::Param(*CachedCommandLine, TEXT("Debug"));
|
|
||||||
|
|
||||||
if (GameLiftConfig.bDebugMode)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Debug mode: ENABLED"));
|
|
||||||
#if UE_BUILD_DEBUG
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Command Line Arguments: %s"), *CachedCommandLine);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
GameLiftConfig.ServerPort = GetConfiguredOrDefaultPort();
|
|
||||||
GameLiftConfig.bIsAnywhereFleet = FParse::Param(*CachedCommandLine, TEXT("glAnywhere"));
|
|
||||||
|
|
||||||
if (GameLiftConfig.bIsAnywhereFleet)
|
|
||||||
{
|
|
||||||
UE_LOGFMT(LogShooterGameMode, Log, "GameLift Anywhere Fleet Command Line Parsing");
|
|
||||||
UE_LOGFMT(LogShooterGameMode, Log, "======Command Line Parameters======");
|
|
||||||
|
|
||||||
UE_LOGFMT(LogShooterGameMode, Log, "===================================");
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void AShooterGameMode::InitGame_original(const FString& MapName, const FString& Options, FString& ErrorMessage)
|
|
||||||
{
|
|
||||||
Super::InitGame(MapName, Options, ErrorMessage);
|
|
||||||
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("[%s] Parsing CLI"), *FDateTime::UtcNow().ToString(TEXT("%Y%m%d-%H%M%S")));
|
|
||||||
CachedCommandLine = FCommandLine::Get();
|
|
||||||
bool bIsCriticalError = false;
|
|
||||||
|
|
||||||
if (bDebugMode)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Debug mode: ENABLED"));
|
|
||||||
#if UE_BUILD_DEBUG
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Command Line Arguments: %s"), *CachedCommandLine);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
ServerPort = GetConfiguredOrDefaultPort();
|
|
||||||
|
|
||||||
bIsAnywhereFleet = FParse::Param(*CachedCommandLine, TEXT("glAnywhere"));
|
|
||||||
if (bIsAnywhereFleet)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("GameLift Anywhere Fleet Command Line Parsing"));
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("======Command Line Parameters======"));
|
|
||||||
|
|
||||||
if (!FParse::Value(*CachedCommandLine, TEXT("fleetID="), FleetId))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("FleetId Missing in Command Line"));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Fleet ID: %s"), *FleetId);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!FParse::Value(*CachedCommandLine, TEXT("authtoken="), AuthToken))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("AuthToken Missing in Command Line"));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (bDebugMode)
|
|
||||||
{
|
|
||||||
FString TokenHash = GetSHA256Hash(AuthToken);
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("AuthToken: %s"), *TokenHash);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("AuthToken Length: %d"), AuthToken.Len());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!FParse::Value(*CachedCommandLine, TEXT("hostId="), HostId))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("HostId Missing in Command Line"));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Host ID: %s"), *HostId);
|
|
||||||
}
|
|
||||||
if (!FParse::Value(*CachedCommandLine, TEXT("websocketUrl="), WebSocketUrl))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("WebSocketUrl Missing in Command Line"));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Websocket URL: %s"), *WebSocketUrl);
|
|
||||||
|
|
||||||
bool bValidWebSocket = WebSocketUrl.StartsWith(TEXT("wss://")) || WebSocketUrl.StartsWith(TEXT("ws://"));
|
|
||||||
|
|
||||||
if (bValidWebSocket)
|
|
||||||
{
|
|
||||||
int32 ColonPos = WebSocketUrl.Find(TEXT(":"), ESearchCase::CaseSensitive);
|
|
||||||
int32 SlashPos = WebSocketUrl.Find(TEXT("/"), ESearchCase::CaseSensitive, ESearchDir::FromStart, ColonPos + 1);
|
|
||||||
|
|
||||||
int32 ParsedPort = 443; // Default wss
|
|
||||||
if (WebSocketUrl.StartsWith(TEXT("ws://"))) ParsedPort = 80;
|
|
||||||
|
|
||||||
if (ColonPos != INDEX_NONE && SlashPos != INDEX_NONE)
|
|
||||||
{
|
|
||||||
FString PortStr = WebSocketUrl.Mid(ColonPos + 1, SlashPos - ColonPos - 1);
|
|
||||||
int32 ExplicitPort = FCString::Atoi(*PortStr);
|
|
||||||
if (ExplicitPort > 1024 && ExplicitPort <= 65535) // Privileged ports OK for servers
|
|
||||||
{
|
|
||||||
ParsedPort = ExplicitPort;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
bValidWebSocket = false; // Invalid explicit port
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("WebSocket Parsed Port: %d"), ParsedPort);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!bValidWebSocket)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("Invalid WebSocketUrl: %s"), *WebSocketUrl);
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (ServerPort == 0)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("Invalid or Missing Server Port Number. Shutting Down."));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Port: %d"), ServerPort);
|
|
||||||
}
|
|
||||||
if (!FParse::Value(*CachedCommandLine, TEXT("serverRegion="), ServerRegion))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Warning, TEXT("ServerRegion Missing in Command Line"));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT(">>>Server Region: %s"), *ServerRegion);
|
|
||||||
}
|
|
||||||
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("==================================="));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("GameLift EC2 Fleet"));
|
|
||||||
if (ServerPort == 0)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("Invalid or Missing Server Port Number. Shutting Down."));
|
|
||||||
bIsCriticalError = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Port: %d"), ServerPort);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (bIsCriticalError)
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("Critical Missing or Invalid Arguments in Command Line. Shutting Down."));
|
|
||||||
FPlatformMisc::RequestExit(true);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Command Line Parsed Successfully."));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
int32 AShooterGameMode::GetConfiguredOrDefaultPort() const
|
|
||||||
{
|
|
||||||
// Default Unreal Engine listen/dedicated server port
|
|
||||||
constexpr int32 DefaultPort = 7777;
|
|
||||||
|
|
||||||
int32 CmdPort = DefaultPort;
|
|
||||||
|
|
||||||
// Check if a port was passed via command line: -port=xxxx
|
|
||||||
|
|
||||||
if (FParse::Value(*CachedCommandLine, TEXT("port="), CmdPort) &&
|
|
||||||
GameLiftValidators::IsNumberValid(CmdPort, GameLiftValidators::ServerPortMin, GameLiftValidators::ServerPortMax))
|
|
||||||
{
|
|
||||||
return CmdPort;
|
|
||||||
}
|
|
||||||
|
|
||||||
UE_LOGFMT(LogShooterGameMode, Warning, "Invalid/Missing port in command line - using {0}", DefaultPort);
|
|
||||||
return DefaultPort;
|
|
||||||
}
|
|
||||||
|
|
||||||
FString AShooterGameMode::GetSHA256Hash(const FString& Input)
|
|
||||||
{
|
|
||||||
FTCHARToUTF8 Utf8Input(Input);
|
|
||||||
FSHA256Signature Hash;
|
|
||||||
if (FPlatformMisc::GetSHA256Signature(reinterpret_cast<const uint8*>(Utf8Input.Get()), Utf8Input.Length(), Hash))
|
|
||||||
{
|
|
||||||
return Hash.ToString();
|
|
||||||
}
|
|
||||||
return FString::Printf(TEXT("Fail_%dbytes"), Input.Len());
|
|
||||||
}
|
|
||||||
|
|
||||||
bool AShooterGameMode::ParseAndOutputResult(const FString& InString, FString& OutValue, bool bRequired)
|
|
||||||
{
|
|
||||||
// Returns True if it is a critical error, returns false
|
|
||||||
|
|
||||||
if (!FParse::Value(*InString, TEXT("hostId="), HostId))
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Error, TEXT("HostId Missing in Command Line"));
|
|
||||||
return bRequired;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
UE_LOG(LogShooterGameMode, Log, TEXT("Host ID: %s"), *HostId);
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
bool AShooterGameMode::ValidateFleetId(const FString& InFleetId)
|
|
||||||
{
|
|
||||||
// FRegexMatcher Matcher(FleetIdPattern, InFleetId);
|
|
||||||
// return Matcher.IsMatch() &&
|
|
||||||
// InFleetId.Len() >= 10 &&
|
|
||||||
// InFleetId.Len() < 128;
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
void AShooterGameMode::InitGameLift()
|
|
||||||
{
|
|
||||||
#if WITH_GAMELIFT
|
|
||||||
//TODO: Need to write later, working on parser first.
|
|
||||||
#else
|
|
||||||
UE_LOGFMT(LogShooterGameMode, Warning, "GameLift disabled");
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,115 +0,0 @@
|
|||||||
// Fill out your copyright notice in the Description page of Project Settings.
|
|
||||||
|
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include "CoreMinimal.h"
|
|
||||||
#include "ShooterGameModeBase.h"
|
|
||||||
|
|
||||||
#include "ShooterGameMode.generated.h"
|
|
||||||
|
|
||||||
DECLARE_LOG_CATEGORY_EXTERN(LogShooterGameMode, Log, All);
|
|
||||||
|
|
||||||
struct FProcessParameters;
|
|
||||||
struct FServerParameters;
|
|
||||||
|
|
||||||
struct FGameLiftCliConfig
|
|
||||||
{
|
|
||||||
bool bDebugMode = false;
|
|
||||||
bool bIsAnywhereFleet = false;
|
|
||||||
bool bIsCriticalError = false;
|
|
||||||
|
|
||||||
int32 ServerPort = 0;
|
|
||||||
|
|
||||||
FString AuthToken;
|
|
||||||
FString FleetId;
|
|
||||||
FString HostId;
|
|
||||||
FString WebSocketUrl;
|
|
||||||
FString ServerRegion;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
namespace GameLiftValidators
|
|
||||||
{
|
|
||||||
extern const FRegexPattern FleetIdPattern;
|
|
||||||
extern const int32 FleetIdLengthMin;
|
|
||||||
extern const int32 FleetIdLengthMax;
|
|
||||||
extern const FString ServerRegionPattern;
|
|
||||||
extern const int32 ServerRegionLengthMin;
|
|
||||||
extern const int32 ServerRegionLengthMax;
|
|
||||||
extern const FString WebSocketUrlPattern;
|
|
||||||
extern const int32 WebSocketUrlLengthMin;
|
|
||||||
extern const int32 WebSocketUrlLengthMax;
|
|
||||||
extern const FString AuthTokenPattern;
|
|
||||||
extern const int32 AuthTokenLengthMin;
|
|
||||||
extern const int32 AuthTokenLengthMax;
|
|
||||||
extern const FString HostIdPattern;
|
|
||||||
extern const int32 HostIdLengthMin;
|
|
||||||
extern const int32 HostIdLengthMax;
|
|
||||||
extern const int32 ServerPortMin;
|
|
||||||
extern const int32 ServerPortMax;
|
|
||||||
extern const int32 WebSocketPortMin;
|
|
||||||
extern const int32 WebSocketPortMax;
|
|
||||||
|
|
||||||
bool IsStringValid(const FString& Value, const FRegexPattern& OptionalPattern, int32 Min, int32 Max);
|
|
||||||
bool IsNumberValid(int32 Value, int32 Min, int32 Max);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
UCLASS()
|
|
||||||
class FPSTEMPLATE_API AShooterGameMode : public AShooterGameModeBase
|
|
||||||
{
|
|
||||||
GENERATED_BODY()
|
|
||||||
|
|
||||||
public:
|
|
||||||
AShooterGameMode();
|
|
||||||
|
|
||||||
protected:
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
bool bIsAnywhereFleet = false;
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
FString FleetId;
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
FString AuthToken;
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
FString HostId;
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
FString WebSocketUrl;
|
|
||||||
|
|
||||||
UPROPERTY(Config)
|
|
||||||
FString ServerRegion;
|
|
||||||
|
|
||||||
UPROPERTY(Config, BlueprintReadOnly)
|
|
||||||
int32 ServerPort;
|
|
||||||
|
|
||||||
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
||||||
bool bDebugMode = false;
|
|
||||||
|
|
||||||
virtual void BeginPlay() override;
|
|
||||||
virtual void InitGame(const FString& MapName, const FString& Options, FString& ErrorMessage) override;
|
|
||||||
void InitGame_original(const FString& MapName, const FString& Options, FString& ErrorMessage);
|
|
||||||
|
|
||||||
private:
|
|
||||||
|
|
||||||
FGameLiftCliConfig GameLiftConfig;
|
|
||||||
|
|
||||||
FString CachedCommandLine;
|
|
||||||
TSharedPtr<FProcessParameters> ProcessParameters;
|
|
||||||
TSharedPtr<FServerParameters> ServerParameters;
|
|
||||||
|
|
||||||
int32 GetConfiguredOrDefaultPort() const;
|
|
||||||
static FString GetSHA256Hash(const FString& Input);
|
|
||||||
|
|
||||||
bool ParseAndOutputResult(const FString& InString, FString& OutValue, bool bRequired = false);
|
|
||||||
bool ParseAndValidate(const FString& InArguments, FGameLiftCliConfig& Config);
|
|
||||||
static bool ValidateFleetId(const FString& InFleetId);
|
|
||||||
|
|
||||||
void InitGameLift();
|
|
||||||
};
|
|
||||||
|
|
||||||
@@ -3,14 +3,14 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "CoreMinimal.h"
|
#include "CoreMinimal.h"
|
||||||
#include "GameFramework/GameMode.h"
|
#include "DedicatedServers/Public/Game/DS_GameMode.h"
|
||||||
#include "ShooterGameModeBase.generated.h"
|
#include "ShooterGameModeBase.generated.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
UCLASS()
|
UCLASS()
|
||||||
class FPSTEMPLATE_API AShooterGameModeBase : public AGameMode
|
class FPSTEMPLATE_API AShooterGameModeBase : public ADS_GameMode
|
||||||
{
|
{
|
||||||
GENERATED_BODY()
|
GENERATED_BODY()
|
||||||
public:
|
public:
|
||||||
|
|||||||
@@ -11,5 +11,6 @@ public class FPSTemplateEditorTarget : TargetRules
|
|||||||
DefaultBuildSettings = BuildSettingsVersion.V6;
|
DefaultBuildSettings = BuildSettingsVersion.V6;
|
||||||
IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_7;
|
IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_7;
|
||||||
ExtraModuleNames.Add("FPSTemplate");
|
ExtraModuleNames.Add("FPSTemplate");
|
||||||
|
ExtraModuleNames.Add("DedicatedServers");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,5 +11,6 @@ public class FPSTemplateServerTarget : TargetRules
|
|||||||
DefaultBuildSettings = BuildSettingsVersion.V6;
|
DefaultBuildSettings = BuildSettingsVersion.V6;
|
||||||
IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_7;
|
IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_7;
|
||||||
ExtraModuleNames.Add("FPSTemplate");
|
ExtraModuleNames.Add("FPSTemplate");
|
||||||
|
ExtraModuleNames.Add("DedicatedServers");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user