x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

AnswerHub Maintenance

Background maintenance is scheduled to occur between 9 - 11am EDT on Tuesday, May 21. Site operation may be slower than normal during this time and a brief interruption in operation may be observed

Internet multiplayer

Good day!

I have watched the networking basics video series as well as various other online tutorials, in order to understand multiplayer in UE4. What I am not clear about, is if the built-in multiplayer support, as described in the Networking Basics videos, are limited to LAN, or do they apply to over-the-internet gameplay as well?

I have tried running a simple multiplayer game, that does work when I test it from the editor with 2 players. I run it as host on a server machine and try to connect to it from another machine, not on the same network, but with port 80 (internet) open.

This does not work though. I get no errors, but my game instances clearly do not see each other.

Do I need to go through something like Steam for internet play in UE4? Or am I just doing something wrong? Could you please help me understand what I need in order to be able to play multiplayer UE4 game from client machines to an internet-based server machine?

Thank you!

Product Version: UE 4.10
Tags:
more ▼

asked Jan 07 '16 at 07:06 AM in Using UE4

avatar image

Marius
31 7 11 12

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

In editor, you have in options of playing, the fact that client are auto connecting to server. You can disable this option, and test your own way to connect.

From my side, I don't use anything as subsystem, I have a Mainmenu with a connect button, and a textbox with the ip filled by user. Next I wrote a tiny C++ code to connect to server

 bool UMyGameInstance::ClientTravelToServer(FString ip) {
 
     UEngine* const Engine = GetEngine();
 
     Engine->SetClientTravel(WorldContext->World(), (*ip), TRAVEL_Absolute);
     return true;
 }


Next over internet, it seems that UE uses UDP and TCP, so check that your NAT authorizes UDP outgoing on default port (7777).

more ▼

answered Jan 11 '16 at 09:18 AM

avatar image

thyshimrod
399 22 11 39

avatar image Marius Jan 15 '16 at 05:46 PM

Thanks. So do I understand correctly that basically, UE4 supports internet play, the only requirement is proper UDP and TCP configuration (opening ports)?

(comments are locked)
10|2000 characters needed characters left

The Unreal Engine server process is listening on port 7777. Try to open this port on your server but don't expect the session discovery to work, it will work only over the same LAN. Just try to connect by IP address to the server. If you use the Steam online subsystem you can leverage a set of services like matchmaking. Make sure to add these lines to your gameengine.ini to enable the default online subsystem:

 [OnlineSubsystem]
 DefaultPlatformService=Null

more ▼

answered Jan 07 '16 at 05:44 PM

avatar image

Giuseppe Portelli
86 1 5 18

avatar image gedamial Mar 28 '16 at 09:06 PM

How can I connect to a session via IP? Please check this https://answers.unrealengine.com/questions/395213/join-server-on-public-ip-address.html

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question