Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
benui-dev committed Oct 8, 2022
0 parents commit fc1763d
Show file tree
Hide file tree
Showing 127 changed files with 389 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Auto detect text files and perform LF normalization
* text=auto
74 changes: 74 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# Visual Studio 2015 user specific files
.vs/

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app
*.ipa

# These project files can be generated by the engine
*.xcodeproj
*.xcworkspace
*.sln
*.suo
*.opensdf
*.sdf
*.VC.db
*.VC.opendb

# Precompiled Assets
SourceArt/**/*.png
SourceArt/**/*.tga

# Binary Files
Binaries/*
Plugins/*/Binaries/*

# Builds
Build/*

# Whitelist PakBlacklist-<BuildConfiguration>.txt files
!Build/*/
Build/*/**
!Build/*/PakBlacklist*.txt

# Don't ignore icon files in Build
!Build/**/*.ico

# Built data for maps
*_BuiltData.uasset

# Configuration files generated by the Editor
Saved/*

# Compiled source files for the engine to use
Intermediate/*
Plugins/*/Intermediate/*

# Cache files for the editor to use
DerivedDataCache/*
8 changes: 8 additions & 0 deletions .idea/.idea.SlateExample.dir/.idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions .idea/.idea.SlateExample.dir/.idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.SlateExample.dir/.idea/indexLayout.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.SlateExample/.idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions .idea/.idea.SlateExample/.idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.SlateExample/.idea/indexLayout.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file added Config/DefaultEditor.ini
Empty file.
43 changes: 43 additions & 0 deletions Config/DefaultEngine.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@


[/Script/EngineSettings.GameMapsSettings]
GameDefaultMap=/Game/Map_Example.Map_Example
EditorStartupMap=/Game/Map_Example.Map_Example

[/Script/HardwareTargeting.HardwareTargetingSettings]
TargetedHardwareClass=Desktop
AppliedTargetedHardwareClass=Desktop
DefaultGraphicsPerformance=Maximum
AppliedDefaultGraphicsPerformance=Maximum

[/Script/WindowsTargetPlatform.WindowsTargetSettings]
DefaultGraphicsRHI=DefaultGraphicsRHI_DX12

[/Script/Engine.RendererSettings]
r.GenerateMeshDistanceFields=True
r.DynamicGlobalIlluminationMethod=1
r.ReflectionMethod=1
r.Shadow.Virtual.Enable=1

[/Script/WorldPartitionEditor.WorldPartitionEditorSettings]
CommandletClass=Class'/Script/UnrealEd.WorldPartitionConvertCommandlet'

[/Script/Engine.Engine]
+ActiveGameNameRedirects=(OldGameName="TP_Blank",NewGameName="/Script/SlateExample")
+ActiveGameNameRedirects=(OldGameName="/Script/TP_Blank",NewGameName="/Script/SlateExample")
+ActiveClassRedirects=(OldClassName="TP_BlankGameModeBase",NewClassName="SlateExampleGameModeBase")

[/Script/AndroidFileServerEditor.AndroidFileServerRuntimeSettings]
bEnablePlugin=True
bAllowNetworkConnection=True
SecurityToken=AA8AA99B49693C61D3A94D96F374948B
bIncludeInShipping=False
bAllowExternalStartInShipping=False
bCompileAFSProject=False
bUseCompression=False
bLogFiles=False
bReportStats=False
ConnectionType=USBOnly
bUseManualIPAddress=False
ManualIPAddress=

3 changes: 3 additions & 0 deletions Config/DefaultGame.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

[/Script/EngineSettings.GeneralProjectSettings]
ProjectID=4AEF21424235771A92646F8AA84E72D9
31 changes: 31 additions & 0 deletions Config/HoloLens/HoloLensEngine.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@


[/Script/HoloLensPlatformEditor.HoloLensTargetSettings]
bBuildForEmulation=False
bBuildForDevice=True
bUseNameForLogo=True
bBuildForRetailWindowsStore=False
bAutoIncrementVersion=False
bShouldCreateAppInstaller=False
AppInstallerInstallationURL=
HoursBetweenUpdateChecks=0
bEnablePIXProfiling=False
TileBackgroundColor=(B=64,G=0,R=0,A=255)
SplashScreenBackgroundColor=(B=64,G=0,R=0,A=255)
+PerCultureResources=(CultureId="",Strings=(PackageDisplayName="",PublisherDisplayName="",PackageDescription="",ApplicationDisplayName="",ApplicationDescription=""),Images=())
TargetDeviceFamily=Windows.Holographic
MinimumPlatformVersion=
MaximumPlatformVersionTested=10.0.18362.0
MaxTrianglesPerCubicMeter=500.000000
SpatialMeshingVolumeSize=20.000000
CompilerVersion=Default
Windows10SDKVersion=10.0.18362.0
+CapabilityList=internetClientServer
+CapabilityList=privateNetworkClientServer
+Uap2CapabilityList=spatialPerception
bSetDefaultCapabilities=False
SpatializationPlugin=
ReverbPlugin=
OcclusionPlugin=
SoundCueCookQualityIndex=-1

Binary file added Content/Map_Example.umap
Binary file not shown.
Binary file added Content/Map_Example_HLOD0_Instancing.uasset
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
22 changes: 22 additions & 0 deletions SlateExample.uproject
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"FileVersion": 3,
"EngineAssociation": "5.0",
"Category": "",
"Description": "",
"Modules": [
{
"Name": "SlateExample",
"Type": "Runtime",
"LoadingPhase": "Default"
}
],
"Plugins": [
{
"Name": "ModelingToolsEditorMode",
"Enabled": true,
"TargetAllowList": [
"Editor"
]
}
]
}
14 changes: 14 additions & 0 deletions Source/SlateExample.Target.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Copyright Epic Games, Inc. All Rights Reserved.

using UnrealBuildTool;
using System.Collections.Generic;

public class SlateExampleTarget : TargetRules
{
public SlateExampleTarget( TargetInfo Target) : base(Target)
{
Type = TargetType.Game;
DefaultBuildSettings = BuildSettingsVersion.V2;
ExtraModuleNames.AddRange( new string[] { "SlateExample" } );
}
}
19 changes: 19 additions & 0 deletions Source/SlateExample/BUIHUD.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#include "BUIHUD.h"
#include "SExampleWidget.h"
#include "Widgets/SViewport.h"

ABUIHUD::ABUIHUD(const FObjectInitializer& ObjectInitializer)
: Super(ObjectInitializer)
{
}

void ABUIHUD::BeginPlay()
{
Super::BeginPlay();

MyWidget = SNew(SExampleWidget)
.LabelText(NSLOCTEXT("Example","OhNo","OhNo"));

UGameViewportClient* ViewportClient = GetWorld()->GetGameViewport();
ViewportClient->AddViewportWidgetContent(MyWidget.ToSharedRef());
}
21 changes: 21 additions & 0 deletions Source/SlateExample/BUIHUD.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"
#include "GameFramework/HUD.h"
#include "BUIHUD.generated.h"

UCLASS()
class ABUIHUD : public AHUD
{
GENERATED_BODY()
public:
ABUIHUD(const FObjectInitializer& ObjectInitializer);
//virtual void ShowHUD() override;
//virtual void DrawHUD() override;
protected:
virtual void BeginPlay() override;

TSharedPtr<class SExampleWidget> MyWidget;
};
4 changes: 4 additions & 0 deletions Source/SlateExample/BUIPlayerController.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
// Fill out your copyright notice in the Description page of Project Settings.


#include "BUIPlayerController.h"
10 changes: 10 additions & 0 deletions Source/SlateExample/BUIPlayerController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#pragma once

#include "CoreMinimal.h"
#include "BUIPlayerController.generated.h"

UCLASS()
class ABUIPlayerController : public APlayerController
{
GENERATED_BODY()
};
16 changes: 16 additions & 0 deletions Source/SlateExample/SExampleWidget.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#include "SExampleWidget.h"
#include "SlateOptMacros.h"

BEGIN_SLATE_FUNCTION_BUILD_OPTIMIZATION

void SExampleWidget::Construct(const FArguments& InArgs)
{
ChildSlot
[
SNew(STextBlock)
//.Text(NSLOCTEXT("Example", "HelloWorld", "Hello world!"))
.Text(InArgs._LabelText)
];
}

END_SLATE_FUNCTION_BUILD_OPTIMIZATION
18 changes: 18 additions & 0 deletions Source/SlateExample/SExampleWidget.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#pragma once

#include "CoreMinimal.h"
#include "Widgets/SCompoundWidget.h"

class SExampleWidget : public SCompoundWidget
{
public:
SLATE_BEGIN_ARGS(SExampleWidget)
// : _Text(FText::GetEmpty()) // optional
{} //
SLATE_ARGUMENT(FText, LabelText)
SLATE_END_ARGS()

void Construct(const FArguments& InArgs);
protected:
FText LabelText;
};
15 changes: 15 additions & 0 deletions Source/SlateExample/SlateExample.Build.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// Copyright Epic Games, Inc. All Rights Reserved.

using UnrealBuildTool;

public class SlateExample : ModuleRules
{
public SlateExample(ReadOnlyTargetRules Target) : base(Target)
{
PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs;

PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore" });

PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore", "UMG" });
}
}
6 changes: 6 additions & 0 deletions Source/SlateExample/SlateExample.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Copyright Epic Games, Inc. All Rights Reserved.

#include "SlateExample.h"
#include "Modules/ModuleManager.h"

IMPLEMENT_PRIMARY_GAME_MODULE( FDefaultGameModuleImpl, SlateExample, "SlateExample" );
6 changes: 6 additions & 0 deletions Source/SlateExample/SlateExample.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Copyright Epic Games, Inc. All Rights Reserved.

#pragma once

#include "CoreMinimal.h"

15 changes: 15 additions & 0 deletions Source/SlateExample/SlateExampleGameModeBase.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#include "SlateExampleGameModeBase.h"

#include "BUIHUD.h"

ASlateExampleGameModeBase::ASlateExampleGameModeBase(const FObjectInitializer& ObjectInitializer)
: Super(ObjectInitializer)
{
HUDClass = ABUIHUD::StaticClass();
}

void ASlateExampleGameModeBase::BeginPlay()
{
Super::BeginPlay();

}
Loading

0 comments on commit fc1763d

Please sign in to comment.