Proper way to package to device with client/server project

I think I need help in determining the correct way to package to devices. I feel like I’ve tried all the ways and permutations I can think of. I’ve also searched and read all online material on the subject. I’ve been stuck for a few weeks, so time to ask the experts.

I am trying to run from a device as a client and connect to a dedicated server. I am able to package, deploy and run to IOS and android from Mac or PC.
I am able to connect to my server (DebugGame Server - Win64). But then the device/client immediately disconnects with an error…

LogNet:Warning: Travel Failure: [PackageMissing]:

In looking at the core code, this error seems to be thrown when the engine cannot find the map locally. In otherwords, UEngine::MakeSureMapNameIsValid(Context.PendingNetGame->URL.Map) returns false in the TickWorldTravel function…

void UEngine::TickWorldTravel(FWorldContext& Context, float DeltaSeconds)
{
...
			if (!MakeSureMapNameIsValid(Context.PendingNetGame->URL.Map))
			{
				BrowseToDefaultMap(Context);
				BroadcastTravelFailure(Context.World(), ETravelFailure::PackageMissing, Context.PendingNetGame->URL.RedirectURL);
			}
...
}

Here are my client/server logs and config files

[client][1]

[server][2]

[DefaultGame.ini][3]

[DefaultEngine.ini][4]

My Android client is built from visual studio with (DebugGame Client - Android)
My Windows server is build and launched with (DebugGame Server - Win64)

Note, I do not get this error when I run from a client on PC (DebugGame Client - Win64)

Again, I think it must be my setup which causes the map to not be packaged/cooked to the client correctly?

Any help would be appreciated.

http://www.roskoapp.com/ServerModuleMain/For_Unreal/client.txt
[2]: http://www.roskoapp.com/ServerModuleMain/For_Unreal/server.txt
[3]: http://www.roskoapp.com/ServerModuleMain/For_Unreal/DefaultGame.ini
[4]: http://www.roskoapp.com/ServerModuleMain/For_Unreal/DefaultEngine.ini

Also, I am traveling to the server like this…

ClientTravel(TEXT(“192.168.178.23:7777”), ETravelType::TRAVEL_Absolute);

,

Thanks for being so thorough with the information you’ve provided. Have you tried cleaning up your project if you’ve updated to a newer version of the engine? What I would suggest doing is to start a new project and then either migrating your project over to the new project or copying all of your old content directories to the new project directories. Make sure to copy your source directory if you have one and regenerate the Visual Studio project files and then rebuild and set up the project settings.

Make sure that when you migrate or copy these files over that it’s from a copy of your project in general because we want to test and make sure that this resolves your issue before including your only copy of the project.

[Networking Documentation][1]

Let me know what happens and please provide new logs if needed.

Networking and Multiplayer in Unreal Engine | Unreal Engine 5.1 Documentation

Hi ,

Yes, i’ve tried cleaning up my project several times.
I’ve tried new projects in the following different situations…

  1. PC: windows 7, Visual studio 2015, Unreal Engine 10.2, original main project
  2. PC: windows 7, Visual studio 2015, Unreal Engine 10.2, new project copied from original main project
  3. PC: Formatted and Fresh install of all software. windows 8, Visual studio 2013, Unreal Engine 10.2, new project copied files manually from old directory to new directory
  4. PC: Formatted and Fresh install of all software. windows 10, Visual studio 2015, Unreal Engine 10.4, new project source and content from source control
  5. MAC: Latest os and xcode, Unreal Engine 11 preview 4, new project source and content from source control
  6. PC: windows 10, Visual studio 2015, Unreal Engine 11 preview 6, new project source and content from source control
    (All off the above was using Unreal Engine built from source)

As for configurations…
In Visual Studio…

Development - Client - Android,
DebugGame - Client - Android,
DebugGame - Android,
Development - Client - IOS,
DebugGame - Client - IOS,
DebugGame - IOS,

I’ve also tried in the Editor under packaging settings.

…and also in Unreal FrontEnd, I’ve tried DebugGame and Development

(I’ve used many devices including Nvidia shield tablet, Samsung Galaxy s6, , and ipad 4)

I’ve built, packaged, and cooked an different variations with Visual studio, Editor, Unreal Front End, File->Package Project->All of them, File->Cook content for windows

Could you tell me if i’m am traveling correctly? I am only using the ClientTravel function I specified above. Do i need to specify the map in ClientTravel or something similar?

Important thing to remember, is that everything seems to work normally when running through the editor.
I.E. clicking the play button in the editor( with or without checking the dedicated server and/or run in different process checkboxes)

D

I’ve increased the verbosity on the logs. Maybe it will help?

[verbose-android-client][1]

[verbose-win64-server][2]

[ProjectLauncher.log][3]

http://www.roskoapp.com/ServerModuleMain/For_Unreal/client_android_verbose.txt
[2]: http://www.roskoapp.com/ServerModuleMain/For_Unreal/server_win64_verbose.txt
[3]: http://www.roskoapp.com/ServerModuleMain/For_Unreal/ProjectLauncher.log

,

Have you been able to run a standalone on the same client as the packaged build (i.e. don’t connect to server, just open the map up directly)?

Thanks!

,

Yes, I have been able to run a standalone on the device. It seams to load fine. However, it will not do much because I rely on most of my data from the server. The game will just remain idle on a black screen. But I am sure that it is running and loading things correctly.

D

Hey ,

Thank you for responding with this additional information. We’re still reviewing what may be occurring. We’ll respond back as soon as possible - thanks!

,

Could you either provide your project in a PM on the forums with steps to replicate what you’re experiencing, or provide full reproduction steps to create the project from scratch - exactly as you have? This way, we’ll be able to break down exactly what’s going on and figure out whether or not this is -error or a bug. :slight_smile:

Thanks!

,

I was able to create a blank project from scratch that seems to be able to stay connected to the dedicated server from my android device. (Although it disconnects from a timeout - UNetConnection::Tick: Connection TIMED OUT. Closing connection). That seems like a different problem though. I will look further to see why it works on a blank project and not mine. I’ll respond with my findings as soon as I can.

Thanks!

,

I may have spoke too soon. It appears that a blank project has similar issues. It has identical issues when I ran from an engine 10.4 that was built from source. But when I run without building from source, there are different but similar issues. I think it times out because it cannot find the map. I traced further and found more detailed information about the problem. Basically, the server is telling the client to look for the map in a directory that does not exist on my devices. here is the relevant logs

LogNet: Welcomed by server (Level: /Temp/Autosaves/Game/Maps/UEDPCOlokWorldMap, Game: /Game/Blueprints/OlokGameModeBP.OlokGameModeBP_C)
FAndroidPlatformFile::GetTimeStamp(‘…/…/…/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’)
FAndroidPlatformFile::PathToAndroidPaths(‘…/…/…/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’) => AndroidPath = ‘…/…/…/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’
FAndroidPlatformFile::PathToAndroidPaths(‘…/…/…/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’) => LocalPath = ‘/storage/emulated/0/UE4Game/Olok/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’
FAndroidPlatformFile::PathToAndroidPaths(‘…/…/…/Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’) => AssetPath = ‘Olok/Saved/Autosaves/Game/Maps/UEDPCOlokWorldMap.umap’

So either the server is telling my device to load the map from an incorrect location. or i am not packaging my map to the correct directory.

Any ideas?

If you could provide a sample project along with exact reproduction steps, I can then test it out on my end with exactly what you’re doing and see whether or not a bug is occurring or if there is an error in the steps. Don’t forget to include the way that you’re packaging (UFE or File > Package) as that can make a difference too.

Hey ,

We have not heard back from you in a few days, so we are marking this post as Resolved for tracking purposes. If you are still experiencing the issue you reported, please respond to this message with additional information and we will offer further assistance.

Thank you!

I finally found what was happening with my particular situation. As I initially thought, it was related to how I was setting things up.

Recently, I was running a dedicated server via the Editor. I was then connecting a client through the editor to validate that everything is working. I then tried to connect to the same server from my devices. This apparently is not possible because the editor does not respect the map paths that are set in the project options and uses a temporary directory instead.

I since started building a dedicated server and running it from VS or cmd line. That server provided the correct map to the device and things started working

, I got it working over the weekend :slight_smile: I have posted my answer. Thank you for your help!

That’s wonderful. Thank you for posting how you resolved your issue. :slight_smile: