Hi guys! I’m working on a pure commond line server project, which planned to be a Node Server of a common MMO. This server should be cross-platform, at least in windows&Linux. In order to make the client/server develop workflow equivalent, I want to use some UE4 core features like blueprints, UObject, and some other programming structs that engine offered.
I followed this :
And I got a server excutable ,which I have to open a default map.
The Question is : Can I get a clean one without the graphic stuff in sever mode ,and still keep the editor mode(for blueprint edit).
I found that window platform starts with WinMain. Linux platform starts with main. So if I change the windows launch to command line main, how can I use the engine libs but not to start it’s rendering? Should a including header file can solve all this? Or I have to step to step start the nessasory features of engine?
Shoud I set the build target to PROGRAM? Like ShaderCompileWorker, SlateViewer, and UnrealHeaderTool?
A console automatically pops up when you run your game as a dedicated server. Please, see this link for settting up dedicated servers.
Yes I’s my fault.I’v got the server~. See the answer.Thanks
The Key step which I missed :
1.In visual studio, check the “MyProject” configuration. When you add the Server.Target.cs file to the project, what haven’t automaticly done is that you must right click on the .uproject file, and choose ‘Generate visual studio project file’. After reload your project file, the project can finally get the compile configuration ‘Server *blablabla’.
2. In the Visual studio’s compile configuration manager, select your project configure to ‘server *’ , which we just generated.Because we don’t have this server configuration before we add the Server.Target.cs file and regenerate the project file. Just make sure not only the solution but also the project’s configure is set to ‘server develop’(for example).If you just select the solution’s configure,maybe the project’s configure is not correct.