Initial commit

This commit is contained in:
Philip W 2024-01-26 17:15:00 +00:00 committed by GitHub Enterprise
commit 64fb37a3cd
7 changed files with 444 additions and 0 deletions

95
.gitattributes vendored Normal file
View File

@ -0,0 +1,95 @@
# This .gitattributes has an extensive list of file types. It's not because
# you're meant to store all your raw assets and other files here. These file
# types are here to stop file corruption and allow people to uploaded other
# files if needed, though it's discouraged. If you need to manage raw asset
# files outside of Unreal Engine, then use https://github.falmouth.ac.uk/Games-Academy/art-lfs-repo
# that's what that repo template is for.
## 3D models
*.3dm filter=lfs diff=lfs merge=lfs -text
*.3ds filter=lfs diff=lfs merge=lfs -text
*.blend filter=lfs diff=lfs merge=lfs -text
*.c4d filter=lfs diff=lfs merge=lfs -text
*.collada filter=lfs diff=lfs merge=lfs -text
*.dae filter=lfs diff=lfs merge=lfs -text
*.dxf filter=lfs diff=lfs merge=lfs -text
*.fbx filter=lfs diff=lfs merge=lfs -text
*.jas filter=lfs diff=lfs merge=lfs -text
*.lws filter=lfs diff=lfs merge=lfs -text
*.lxo filter=lfs diff=lfs merge=lfs -text
*.ma filter=lfs diff=lfs merge=lfs -text
*.max filter=lfs diff=lfs merge=lfs -text
*.mb filter=lfs diff=lfs merge=lfs -text
*.obj filter=lfs diff=lfs merge=lfs -text
*.ply filter=lfs diff=lfs merge=lfs -text
*.skp filter=lfs diff=lfs merge=lfs -text
*.stl filter=lfs diff=lfs merge=lfs -text
*.ztl filter=lfs diff=lfs merge=lfs -text
## Audio
*.aif filter=lfs diff=lfs merge=lfs -text
*.aiff filter=lfs diff=lfs merge=lfs -text
*.it filter=lfs diff=lfs merge=lfs -text
*.mod filter=lfs diff=lfs merge=lfs -text
*.mp3 filter=lfs diff=lfs merge=lfs -text
*.ogg filter=lfs diff=lfs merge=lfs -text
*.s3m filter=lfs diff=lfs merge=lfs -text
*.wav filter=lfs diff=lfs merge=lfs -text
*.xm filter=lfs diff=lfs merge=lfs -text
# Video
*.asf filter=lfs diff=lfs merge=lfs -text
*.avi filter=lfs diff=lfs merge=lfs -text
*.flv filter=lfs diff=lfs merge=lfs -text
*.mov filter=lfs diff=lfs merge=lfs -text
*.mp4 filter=lfs diff=lfs merge=lfs -text
*.mpeg filter=lfs diff=lfs merge=lfs -text
*.mpg filter=lfs diff=lfs merge=lfs -text
*.ogv filter=lfs diff=lfs merge=lfs -text
*.wmv filter=lfs diff=lfs merge=lfs -text
## Images
*.bmp filter=lfs diff=lfs merge=lfs -text
*.exr filter=lfs diff=lfs merge=lfs -text
*.gif filter=lfs diff=lfs merge=lfs -text
*.hdr filter=lfs diff=lfs merge=lfs -text
*.iff filter=lfs diff=lfs merge=lfs -text
*.jpeg filter=lfs diff=lfs merge=lfs -text
*.jpg filter=lfs diff=lfs merge=lfs -text
*.pict filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.psd filter=lfs diff=lfs merge=lfs -text
*.tga filter=lfs diff=lfs merge=lfs -text
*.tif filter=lfs diff=lfs merge=lfs -text
*.tiff filter=lfs diff=lfs merge=lfs -text
*.webp filter=lfs diff=lfs merge=lfs -text
*.pdn filter=lfs diff=lfs merge=lfs -text
# Compressed Archive
*.7z filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.rar filter=lfs diff=lfs merge=lfs -text
*.tar filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
# Compiled Dynamic Library
*.dll filter=lfs diff=lfs merge=lfs -text
*.pdb filter=lfs diff=lfs merge=lfs -text
*.so filter=lfs diff=lfs merge=lfs -text
## Fonts
*.otf filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
# Executable/Installer
*.apk filter=lfs diff=lfs merge=lfs -text
*.exe filter=lfs diff=lfs merge=lfs -text
# Documents
*.pdf filter=lfs diff=lfs merge=lfs -text
*.doc filter=lfs diff=lfs merge=lfs -text
*.docx filter=lfs diff=lfs merge=lfs -text
# Binary Files
*.bin filter=lfs diff=lfs merge=lfs -text

View File

@ -0,0 +1,47 @@
# Visual Studio/C++ & Unreal Engine Issues
### I'm Getting Compiler Errors When Run Unreal Engine for Visual Studio
If you are trying to run UE5 from Visual Studio, then close any other UE5 executable windows you have open. If Unreal is already running when you launch it from Visual Studio then it will sometimes prevent Visual Studio from being able to correctly compile your C++ files, which results in a compiler error.
To fix this close all open instances of Unreal Engine. Once you've done that everything will be fine and you should be able to run Unreal from Visual Studio.
### I'm Getting an Error with the Build.bat in the Visual Studio Output Console
This happens when certain executables are already running in the background and haven't shutdown when they're meant to. To fix this open task manager and close `HUB for UE5 runtime traces...` and close every instance of `Runtime Broker` you can find.
Once you've done this, Visual Studio will work again and you can compile code.
`Runtime Broker` controls file permissions on windows and `HUB for UE5 runtime traces...` can sometimes have a file or folder open. From what I know this is a Games Academy specific issue mostly - my guess is that it probably has something to do with the configuration of the University computers. I've not really seen this issue for people who're not using Falmouth Uni/GA computers.
### Stucture's are Unknown when Packaging
If you get an error in the packaging log that looks like this:
```log
PackagingResults: Error: FStructProperty::Serialize Loading: Property 'StructProperty /Game/Game/VisualNovel/BP_VisualNovelManager.BP_VisualNovelManager_C:VisualNovelData.VisualNovelData'. Unknown structure.
PackagingResults: Error: FStructProperty::Serialize Loading: Property 'StructProperty /Game/Game/VisualNovel/BP_VisualNovelManager.BP_VisualNovelManager_C:Dialogue'. Unknown structure.
PackagingResults: Error: FStructProperty::Serialize Loading: Property 'StructProperty /Game/Game/VisualNovel/BP_VisualNovelManager.BP_VisualNovelManager_C:ExecuteUbergraph_BP_VisualNovelManager:CallFunc_Array_Get_Item'. Unknown structure.
PackagingResults: Error: Unknown Cook Failure
```
The the way to fix this is to rename the blueprint structure file(s) it's complaining about. Any name will do. Save all the file(s) that need saving including levels and blueprints that you haven't changed manually.
This will force unreal to update all the references to the blueprint stucture file, and fix the issue.
# Fixing UE5 Setup
### dotnet is not recognized as an internal or external command
If you get an error similar to this one when generating visual studio project files or opening the project for the first time, it's because `.NET 6` is not installed or its environment path is not set.
To fix this locate `C:\program files\dotnet`, and delete the `dotnet` folder if it exists. If it doesn't exist, then don't do anything.
Next download the .NET 6 SDK ([.NET 6 download here](https://dotnet.microsoft.com/en-us/download/dotnet/6.0)) and install it. _(do not download `ASP.NET Core Runtime`, `.NET Desktop Runtime`, `.NET Runtime`, or any other SDK - just the plain `.NET 6` SDK that has everything included)_
This will fix the dotnet error.

View File

@ -0,0 +1,113 @@
# All Materials are Good
Unreal Engine 4 and Unreal Engine 5 are very similar. Most of the features are still the same and a lot of the UE4 tutorials are still relevant in UE5. You only want a UE5 tutorial if it's a new feature that was intoduced in UE5 or if it was completely reworked.
This especially true for C++ and Blueprints, almost nothing has changed between versions for programmers.
These are the main differences between UE4 and UE5:
1. The UI was updated, but a lot of stuff is still in the same place as before.
2. There was internal engine refactoring which doesn't affect you.
3. Addition of Lumen - A new lighting system.
4. Addition of Nanite - A new system for rendering high poly static meshes.
5. Addition of Enhanced Input Subsystem - This is replacing the old input system, but the old system is still available for now so you can still follow old tutorials fine.
UE4 learning materials are still relevant, and sometimes the only thing available for older subjects that haven't changed for years.
_You can also find a lot of official learning materials made by Epic Games on their community website: [https://dev.epicgames.com/community/unreal-engine/learning](https://dev.epicgames.com/community/unreal-engine/learning)_
# Beginners Guide to Unreal
### Learning List
1. [Your First Hour in Unreal Engine 5](https://dev.epicgames.com/community/learning/courses/ZpX/your-first-hour-in-unreal-engine-5-0/RPwK/your-first-hour-in-unreal-engine-5-0-overview)
2. [UE5 Asset Naming Conventions](https://docs.unrealengine.com/5.1/en-US/recommended-asset-naming-conventions-in-unreal-engine-projects/) - Most people working in Unreal use this naming convention. It's something you should use too when working in Unreal Engine.
3. [50 Unreal Engine 5 Tips](https://www.youtube.com/watch?v=iayPiX8tBmQ) - Highly recommend everyone watches this, it also has a list of additional YouTubers that make good Unreal Engine content.
4. [Unreal Slackers](https://unrealslackers.org/) - The biggest Unreal Engine Discord community. They're officially listed on [unrealengine.com](https://unrealengine.com) in the community tab at the top.
5. [Unreal Engine Build a Detective's Office Game Environment](https://dev.epicgames.com/community/learning/courses/WK/unreal-engine-build-a-detective-s-office-game-environment/YOr/unreal-engine-introduction-to-the-detective-s-office-course)
6. [Welcome to Game Development](https://dev.epicgames.com/community/learning/paths/OR/welcome-to-game-development) - Collection of resources by Epic Games.
7. [Mathew Wadstein](https://www.youtube.com/@MathewWadsteinTutorials) - This guy has videos for most blueprint nodes. Type: `unreal wtf <nodenamehere>` into youtube and he will usually have a video on the node.
8. [Introduction to AI with Blueprints](https://dev.epicgames.com/community/learning/courses/67R/unreal-engine-introduction-to-ai-with-blueprints/mX27/introduction-to-ai-with-blueprints)
### Version Control
Be careful when working on files in Unreal Engine. `.ini` config files and code files can have their changes merged. All other files in Unreal, typically with the file extentsion `.umap` or `.uasset`, cannot be merged like text files can be. These are binary files, so you can't merge the work from 2 different people on the same file. To my knowlegde almost everything you create inside the Unreal Engine Editor will be a binary file, so be careful.
Your teams need to maintain good communication to ensure you don't loose work from two people working on the same asset at the same time, and then having to trash someones work because of the merge conflict.
# Art in Unreal
1. [Becoming an Environment Artist in Unreal Engine](https://dev.epicgames.com/community/learning/courses/Gm/becoming-an-environment-artist-in-unreal-engine/VP2/introduction-to-becoming-an-environment-artist-in-unreal-engine)
2. [Unreal Engine Editor Fundamentals - Materials](https://dev.epicgames.com/community/learning/courses/nDz/unreal-engine-unreal-editor-fundamentals-materials/RWR/introduction-to-physically-based-rendering)
3. [Unreal Engine Lighting Essential Concepts and Effects](https://dev.epicgames.com/community/learning/courses/Xwp/unreal-engine-lighting-essential-concepts-and-effects/0ax/lighting-essential-concepts-and-effects-introduction)
# Getting Started with Unreal C++
### C++ Programming Course - Beginner to Advanced
[C++ Programming Course - Beginner to Advanced](https://www.youtube.com/watch?v=8jLOx1hD3_o) - This is a 31 hour video going over all the programming and C++ concepts. Use the `MSVC` compiler, don't use the other options they show like `Mingw` or `Clang LLVM`.
### Unreal Engine Modules
If you want to use C++ in your projects you will need to be familiar with adding modules to your project. Unfortunately this isn't taught very well despite how simple it is. Not knowing how to add modules will cause linker errors at compile-time preventing the project from compiling.
I can't find any simple learning materials. For anyone getting started learning Unreal C++ reach out to me _(`rr262471`/`Rian Rutherford`)_ while I'm at the GA and I might be able to give you a quick 5 minute crash course while I'm there if I have the time.
1. [Build.cs & Target.cs](https://unrealcommunity.wiki/build.cs-hv582z08)
2. [Improving Code Structure with Unreal Engine's C++ Modules](https://dev.epicgames.com/community/learning/tutorials/xJ/improving-code-structure-with-unreal-engine-s-c-modules) - This goes way too indepth and you don't need to know 90% of the content in the video, but it's a good watch if you want to learn how to make you own Unreal Engine modules and what they are.
### Opening The Project: For Programmers
If you're a programmer and plan on doing work in C++ you should right click the `<yourgame>.uproject` file and select the `Generate Visual Studio project files` option. When this is complete double click the `<yourgame>.sln` file and run the game from Visual Studio by clicking `Local Windows Debugger`. Whenever you code in C++ you should close UE5 and recompile it from VS.
If you are not doing anything in C++, then you can open the project straight from double clicking `<yourgame>.uproject`. Make sure you click yes on the prompt asking to compile. UE5 will take awhile to open because it's compiling C++ binaries in the background.
If UE5 is being weird, delete all the cache files/folders & generated files/folders, then reopen the project from Visual Studio so it's forced to compile everything correctly and you will catch any compiler errors if anything is wrong.
### I don't know how to setup VS2022 for Unreal Engine 5
Follow this guide: [Setting Up Visual Studio Environment for C++](https://docs.unrealengine.com/5.1/en-US/setting-up-visual-studio-development-environment-for-cplusplus-projects-in-unreal-engine/)
### Garbage Collection
[Garbage Collection](https://unrealcommunity.wiki/garbage-collection-36d1da) When using pointers on class member variables, that contains a type inheriting from `UObject`, you need to have a `UPROPERTY` macro attached to the variable. This is because `UPROPERTY` helps with tracking memory for the garbage collector.
# Multiplayer in Unreal
_Note - You can do multiplayer programming in Blueprints or C++. For basic applications Blueprints are fine, but they do have limitations because they don't have access to everything multiplayer like C++ does._
1. [Unreal Docs - Networking and Multiplayer](https://docs.unrealengine.com/5.1/en-US/networking-and-multiplayer-in-unreal-engine/)
2. Wizard Cell:
1. [Unreal Engine Multiplayer Tips and Tricks](https://wizardcell.com/unreal/multiplayer-tips-and-tricks/)
2. [Unreal Engine Persistent Data Compendium](https://wizardcell.com/unreal/persistent-data/)
3. [Replicated Properties vs RPCs](https://forums.unrealengine.com/t/replicated-properties-vs-rpcs/264973) - Article written by Alex K. (An Unreal Engine Staff Member).
4. [Multiplayer Network Compendium](https://cedric-neukirchen.net/docs/category/multiplayer-network-compendium/)
5. [Unreal Engine - Correct stateful replication](https://vorixo.github.io/devtricks/stateful-events-multiplayer/)
6. [Understanding replication atomicity in Unreal Engine](https://vorixo.github.io/devtricks/atomicity/)
7. [Send inputs immediately to server or in an input cache periodically in network game?](https://stackoverflow.com/questions/28017244/send-inputs-immediately-to-server-or-in-an-input-cache-periodically-in-network-g)
8. [Fast-Paced Multiplayer (Part III): Entity Interpolation](https://www.gabrielgambetta.com/entity-interpolation.html)
9. [Fix Your Timestep!](https://gafferongames.com/post/fix_your_timestep/)
10. [Netcode done right with Jay Mattis of High Horse Entertainment // Between II Servers EP10 - YouTube](https://www.youtube.com/watch?v=fFP7c59ezjo)
11. [How Multiplayer Games Work - YouTube](https://www.youtube.com/watch?v=KBBJqPL5-eU)
12. [Everything you need to know about Tick Rate, Lag, Netcode, Interpolation and Etc. - Reddit](https://www.reddit.com/r/Blackops4/comments/9qkode/everything_you_need_to_know_about_tick_rate_lag/)
13. [Overwatch Gameplay Architecture and Netcode - YouTube GDC](https://www.youtube.com/watch?v=zrIY0eIyqmI)
14. [It IS Rocket Science! The Physics of Rocket League Detailed - YouTube GDC](https://www.youtube.com/watch?v=ueEmiDM94IE)
15. [Networked Movement in the Character Movement Component - UE5 Docs](https://docs.unrealengine.com/5.1/en-US/understanding-networked-movement-in-the-character-movement-component-for-unreal-engine/)
16. [The right way to Lerp in Unity (with examples)](https://gamedevbeginner.com/the-right-way-to-lerp-in-unity-with-examples/) - This is still relevant in Unreal Engine.
# Fun Reading
1. [The ShooterGame vulnerability that was spread to many games](https://vorixo.github.io/devtricks/shootergame-vulnerability/)

8
Game/.gitattributes vendored Normal file
View File

@ -0,0 +1,8 @@
# To keep the template organised, all unreal engine specific lfs stuff is stored in this file.
# This also means your unreal project must be in the same directory or subdirectory of this file.
# From what I know, all .uasset files are serialized binary data from computer memory.
# If a .uasset file is corrupt, you can't save it. Your only option is to revert to a
# previous commit before the corruption - assuming you have a commit history on the corrupt file.
*.uasset filter=lfs diff=lfs merge=lfs -text
*.umap filter=lfs diff=lfs merge=lfs -text

109
Game/.gitignore vendored Normal file
View File

@ -0,0 +1,109 @@
# This .gitignore goes back to the original Unreal Engine template we had in the GA from 2018-2022.
# It was made using toptal.com. The file is still accurate, so it hasn't been touched.
# If you are tempted to add the Platforms folder to the .gitignore, I wouldn't bother.
# It's a config folder that doesn't matter for most GA students and can be deleted usually.
# In UE 5.3 or 5.4 this will be fixed and unreal engine wont generate it unless you actually
# need the config files for your project.
# If someone adds Platforms to .gitignore it will be forgotten and someone in the future is going to
# have issues with their project because the config file wasn't committed to version control.
# This is why it's better to leave that folder out of .gitignore
# Created by https://www.toptal.com/developers/gitignore/api/unrealengine
# Edit at https://www.toptal.com/developers/gitignore?templates=unrealengine
### UnrealEngine ###
# 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
.vsconfig
# 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/*
### UnrealEngine Patch ###
# Don't ignore icon and splash images for mobile app
!Build/IOS/Resources/
Build/IOS/Resources/*
!Build/IOS/Resources/Graphics/
Build/IOS/Resources/Graphics/*
!Build/IOS/Resources/Graphics/*.png
!Build/Android/res/
Build/Android/res/*
!Build/Android/res/*/
Build/Android/res/*/*
!Build/Android/res/*/*.png
# End of https://www.toptal.com/developers/gitignore/api/unrealengine
### MacOS ###
.DS_Store

25
Game/readme.md Normal file
View File

@ -0,0 +1,25 @@
# Introduction
This is the **ROOT** folder for the unreal game project.
_NOTE - Unreal has blur enabled by default, disable this in project settings if you don't want blur._
# Adding UE5 Game Project
1. Open unreal, select a template, and create the project template anywhere.
2. Open the **ROOT** folder of the UE5 project you just created and copy `yourgame.uproject`, `Content`, `Config`, and `Source` into this folder.
3. If your `yourgame.uproject` file and `Content`, `Config`, `Source` folders are in the same directory as the repositories `.gitignore` file, then your setup is correct.
Once you've completed the above steps you're ready to open the project and start working.
# Opening The Project: For Programmers
If you're a programmer and plan on doing work in C++ you should right click the `yourgame.uproject` file and select the `Generate Visual Studio project files` option. When this is complete double click the `yourgame.sln` file and run the game from Visual Studio by clicking `Local Windows Debugger`. Whenever you code in C++ you should close UE5 and recompile it from VS.
If you are not doing anything in C++, then you can open the project straight from double clicking `yourgame.uproject`. Make sure you click yes on the prompt asking to compile. UE5 will take awhile to open because it's compiling C++ binaries in the background.
If UE5 is bing weird delete all the cache files/folders & generated files/folders, then lauch it from Visual Studio so it's forced to compile everything correctly and you will catch any compile-time bugs if anything is wrong.

47
readme.md Normal file
View File

@ -0,0 +1,47 @@
# Introduction
This is a Unreal Engine template for 5.1 or greater.
The template was made by **Rian Rutherford** _(rr262471)_. To make the template, I used the pervious UE4 template as a starting point.
`Documentation` is an optional folder, it can be deleted if you don't want it.
If you want, you can rename the `Game` folder to something else. What is important is to make sure whatever the folder name, it has the original `.gitignore` and `.gitattributes` file inside.
If you are using Unreal Engine for the first time, or a first time UE5 C++ programmer, you need to read the [Project Root Readme](Game/readme.md). It has information for setting up your Unreal Engine 5 project with the template, and opening the project as a programmer for coding in C++.
# Table of Contents
1. [Project Root Readme](Game/readme.md)
2. [Learning Resources](Documentation/learning-resources.md)
1. [Beginners Guide to Unreal](Documentation/learning-resources.md#beginners-guide-to-unreal)
2. [Getting Started with Unreal C++](Documentation/learning-resources.md#getting-started-with-unreal-c)
3. [Multiplayer in Unreal](Documentation/learning-resources.md#multiplayer-in-unreal)
3. [Bugs & Compile Errors](Documentation/bugs-&-compile-errors.md)
# WARNING!!!
Do not put in development or completed project assets in this repository. When you import assets into unreal they're taken into unreal and changed into `.uasset` files. Because of this it's wasteful to put the original development assets in the game repository. Doing so bloats the project and increases cloning times of the project for everyone.
Instead you should have another repo that uses the [art-lfs-repo](https://github.falmouth.ac.uk/Games-Academy/art-lfs-repo) template. This is where you put your development assets like your models and textures while working on them, including your completed ones. Then when you're done, you import them into Unreal Engine (and UE5 will store the files internally in its own format).
# UE5 Stucture & Organisation
1. [UE5 Directory Structure](https://docs.unrealengine.com/5.1/en-US/unreal-engine-directory-structure/)
2. [UE5 Asset Naming Conventions](https://docs.unrealengine.com/5.1/en-US/recommended-asset-naming-conventions-in-unreal-engine-projects/)
# Other Useful Links
1. [UE5 Command-Line Arguments](https://docs.unrealengine.com/latest/en-US/command-line-arguments-in-unreal-engine/)
2. [C++ UPROPERTY Specifiers](https://docs.unrealengine.com/latest/en-US/unreal-engine-uproperties/)
3. [C++ UFUNCTION Specifiers](https://docs.unrealengine.com/latest/en-US/ufunctions-in-unreal-engine/)
4. [C++ UCLASS Specifiers](https://docs.unrealengine.com/4.26/en-US/ProgrammingAndScripting/GameplayArchitecture/Classes/)
5. [C++ API Reference](https://docs.unrealengine.com/latest/en-US/API/)