Unreal Engine 4
Last updated
Last updated
1-1. In the window shown below, which appears immediately after launching the UE4 Editor, select 'Game', which is circled in red in the screenshot, and when the 'Open Project' button changes to 'Next', press the 'Next' button.
Solution Configuration : Development Editor
Solution Platform : Win64
Specify the ProudNet library and header file paths in C# code in the (project name).build.cs file.
Open the cs file and there will be a class with the same project name automatically generated by UE4 Editor. The class is currently held only by the creator.
If you look at the creator's body, you can see a few lines of annotation at the back. Put the code behind the annotation specifying the reference path to the ProudNet library and header file.
To specify the ProudNet library reference path, pass the library path string to the Add function of the PublicAdditionalLibraries object. E.g.: > PublicAdditionalLibraries.Add("D:\ProudNet1.7.48971-master\ProudNet\lib\x64\v140\Release\ProudNetClient.lib")
To specify the ProudNet header file reference path, pass the path to the ProudNet include folder to the Add function of the global object called PublicIncludepaths. E.g.: > PublicIncludePaths.Add("D:\ProudNet1.7.48971-master\ProudNet)
UE4 projects that integrate with ProudNet must be built in 64-bit, so enclose the two previous sentences in curly braces and add an if statement above them.
The lib files required for IOS and Android builds are also enclosed in an if statement.
Below is an example with commenting removed.
For iOS and Android, please refer to ProudNet\lib\NDK\r20\cmake\clangDebug\arm64-v8a\libProudNetClient.a instead of ProudNet\lib\x64\v140\Release\libProudNetClient.lib.
Please do not set it to the path in the example code above, but to the path where your actual Proudnet is installed.
As in the example above, you can create a CNetClient normally without any compilation errors.
Please refer to the link below.
Reference
You must additionally specify the path to the libiconv.2.tbd library.
If you do not specify it, you will get iconv-related linking errors at build time.
Please refer to the link below.
Reference