Difference between revisions of "Building PSUnreal on Windows"
Jump to navigation
Jump to search
(15 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
* Generate project files, by right clicking on | == Reference docs == | ||
* Open Visual Studio ''' | |||
* Open | Check this page as reference: https://wiki.unrealengine.com/Dedicated_Server_Guide_%28Windows_%26_Linux%29 | ||
* Select " | |||
There are two ways to compile and run your project: | |||
* Compiling the client without editor, and you will then need cooked content (prepared art files) | |||
* Compiling the editor and then running/debugging the game within the editor. Please note VS breakpoints will work also in this mode | |||
All non-editor builds require cooked content, however, you can run an editor build with the "-game" command line flag to run the game directly using the editor data; please note however that this will be slower than a cooked build as the editor is essentially processing assets on the fly. | |||
== Compiling the client without editor == | |||
* Generate project files, by right clicking on PSUnreal.uproject and "Generate Visual Studio project files" | |||
* Open Visual Studio '''2017''' | |||
* Open PSUnreal.sln | |||
* Select "PSUnreal" project from the left tree view and "DebugGame Client" as configuration from the top dropdown | |||
* Compile (about 30 minutes on my PC) | |||
* Select "PSUnreal" project from the left tree view and "DebugGame Server" as configuration from the top dropdown | |||
* Compile | * Compile | ||
* | * Cook your content with C:\Luca\UnrealEngine\Engine\Binaries\Win64\UE4Editor-cmd.exe "C:\Users\Luke\Documents\Unreal Projects\PSUnreal\PSUnreal.uproject" -run=cook -targetplatform=Windows | ||
* Start the client in debug mode | |||
* | |||
* | == Compiling the editor and running the game from it == | ||
* Select " | |||
In this mode you wll use the Editor to run/debug the game | |||
* Generate project files, by right clicking on PSUnreal.uproject and "Generate Visual Studio project files" | |||
* Open Visual Studio '''2017''' | |||
* Open PSUnreal.sln | |||
* Select "PSUnreal" project from the left tree view and "DebugGame Editor" as configuration from the top dropdown | |||
* NOTE: DebugGame configuration builds the engine as optimized, but leaves the game code debuggable. This configuration is ideal for debugging only game modules. | |||
* Compile | * Compile | ||
There are different ways to launch the client in debug mode: | |||
1) | |||
* Select the DebugGameEditor configuration | |||
* From VS properties on PSUnreal add command line -debug -game | |||
* It will launch directly without going through the editor | |||
2) | |||
* Select the DebugGameEditor configuration | |||
* From VS properties on PSUnreal remove -game from command line | |||
* It will launch the Editor, then you press "Play" in the editor. The breakpoints placed in VS are working as expected. | |||
== Checking default map == | |||
In your project directory there is a DefaultEngine.ini which tells the client and server which map to load as default in particular: | |||
GameDefaultMap=/Game/ThirdPerson/Maps/MainMenu | |||
ServerDefaultMap=/Game/ThirdPerson/Maps/MainMenu | |||
== Launching the server == | |||
* Install mysql server and launch it | |||
* Create the PlaneShift database as if it was the old PS. See https://svn.code.sf.net/p/planeshift/code/trunk/docs/compiling.html In particular: | |||
** svn co https://svn.code.sf.net/p/planeshift/code/trunk planeshift | |||
** then run the command src/server/database/mysql/create_all.sql to create all ps tables and dummy data | |||
* Select the "DebugGame Editor" configuration (if you select Development Editor then the Editor will start instead of the server) | |||
* From VS properties on PSUnreal , select "Debugging" and then add this in the command line: -server -log | |||
* The resulting property will be like: "$(SolutionDir)$(ProjectName).uproject" -server -log | |||
* It will launch directly without going through the editor |
Revision as of 10:52, 14 January 2019
Reference docs
Check this page as reference: https://wiki.unrealengine.com/Dedicated_Server_Guide_%28Windows_%26_Linux%29
There are two ways to compile and run your project:
* Compiling the client without editor, and you will then need cooked content (prepared art files) * Compiling the editor and then running/debugging the game within the editor. Please note VS breakpoints will work also in this mode
All non-editor builds require cooked content, however, you can run an editor build with the "-game" command line flag to run the game directly using the editor data; please note however that this will be slower than a cooked build as the editor is essentially processing assets on the fly.
Compiling the client without editor
- Generate project files, by right clicking on PSUnreal.uproject and "Generate Visual Studio project files"
- Open Visual Studio 2017
- Open PSUnreal.sln
- Select "PSUnreal" project from the left tree view and "DebugGame Client" as configuration from the top dropdown
- Compile (about 30 minutes on my PC)
- Select "PSUnreal" project from the left tree view and "DebugGame Server" as configuration from the top dropdown
- Compile
- Cook your content with C:\Luca\UnrealEngine\Engine\Binaries\Win64\UE4Editor-cmd.exe "C:\Users\Luke\Documents\Unreal Projects\PSUnreal\PSUnreal.uproject" -run=cook -targetplatform=Windows
- Start the client in debug mode
Compiling the editor and running the game from it
In this mode you wll use the Editor to run/debug the game
- Generate project files, by right clicking on PSUnreal.uproject and "Generate Visual Studio project files"
- Open Visual Studio 2017
- Open PSUnreal.sln
- Select "PSUnreal" project from the left tree view and "DebugGame Editor" as configuration from the top dropdown
- NOTE: DebugGame configuration builds the engine as optimized, but leaves the game code debuggable. This configuration is ideal for debugging only game modules.
- Compile
There are different ways to launch the client in debug mode:
1)
- Select the DebugGameEditor configuration
- From VS properties on PSUnreal add command line -debug -game
- It will launch directly without going through the editor
2)
- Select the DebugGameEditor configuration
- From VS properties on PSUnreal remove -game from command line
- It will launch the Editor, then you press "Play" in the editor. The breakpoints placed in VS are working as expected.
Checking default map
In your project directory there is a DefaultEngine.ini which tells the client and server which map to load as default in particular:
GameDefaultMap=/Game/ThirdPerson/Maps/MainMenu ServerDefaultMap=/Game/ThirdPerson/Maps/MainMenu
Launching the server
- Install mysql server and launch it
- Create the PlaneShift database as if it was the old PS. See https://svn.code.sf.net/p/planeshift/code/trunk/docs/compiling.html In particular:
- svn co https://svn.code.sf.net/p/planeshift/code/trunk planeshift
- then run the command src/server/database/mysql/create_all.sql to create all ps tables and dummy data
- Select the "DebugGame Editor" configuration (if you select Development Editor then the Editor will start instead of the server)
- From VS properties on PSUnreal , select "Debugging" and then add this in the command line: -server -log
- The resulting property will be like: "$(SolutionDir)$(ProjectName).uproject" -server -log
- It will launch directly without going through the editor