EOS: Testing Multiplayer

Requirements

  • Unreal Engine 4.25+
  • EOSCore:: 1.8.0+
  • Separate Epic Accounts
    Depending on how many game instances you want to test simultaneously, you must have a unique Epic account for each instance
  • Configured OnlineSubsystem

The best way when testing multiplayer is to use the DevTool that is provided by the EOS SDK.
You can obtain the DevTool from the EOS Developer Portal, “Download SDK

After obtaining your copy of the DevTool, launch the application and create your token.
Remember that for each instance you must use a separate Epic Account, using the same Epic account for multiple instances will not work!

DevTool Credentials

Testing

You can play test using either Standalone or launching from Command line

Authenticating with the DevTool

Logged In

Find and join your session

EOS: Logging In / Authentication

EOSCore version 1.8.0 now has a Login function that is meant to simplify the login process.

Logging in via Device ID

AuthType: Password
CredentialsType: DeviceId Access Token

LoginId is your DisplayName
Token is unused
Data is unused

Logging in via Epic Portal

AuthType: AccountPortal
CredentialsType: Epic

LoginId is unused
Token is unused
Data is unused

Loggin in with Persistent Auth (saved credentials)

AuthType: PersistentAuth
CredentialsType: Epic

LoginId is unused
Token is unused
Data is unused

Logging in via DevTool

AuthType: Developer
CredentialsType: Epic

LoginId is the address, example: localhost:1111
Token is the token you specified in the developer tool, example: hulken
Data is unused

Logging in via Async Nodes

If you are logging in “manually” by using the EOS Async Blueprint Nodes, you have to update the UniqueNetId manually. You can do it by adding this event to your PlayerController

EOS Android Multiplayer

Requirements

  • Unreal Engine 4.25+
  • EOSCore:: 1.8.0+

To enable Multiplayer when using an Android Phone, you must edit your AndroidEngine.ini configuration file, this is the android equivilent to DefaultEngine.ini, just copy-paste your settings from the DefaultEngine.ini to your AndroidEngine.ini, see the example below.

This example will allow you to connect using the EOS NAT P2P Interface and enable cross-platform multiplayer.

Project\Config\Android\AndroidEngine.ini

[OnlineSubsystem]
DefaultPlatformService=EOS

[/Script/OnlineSubsystemEOS.NetDriverEOS]
NetConnectionClassName=OnlineSubsystemEOS.NetConnectionEOS
bIsUsingP2PSockets=true

[/Script/Engine.GameEngine]
!NetDriverDefinitions=ClearArray
+NetDriverDefinitions=(DefName="GameNetDriver",DriverClassName="OnlineSubsystemEOS.NetDriverEOS",DriverClassNameFallback="OnlineSubsystemUtils.IpNetDriver")

EOS Dedicated Server

Requirements

  • EOSCore:: v1.8.0+
  • Unreal Engine 4.25+
  • A working Unreal Engine Dedicated Server

DefaultEngine.ini

Since Dedicated Servers don’t need to use Relay Servers, we have to disable the EOS NetDriver, simply removing the declarations here will disable using the EOS NetDriver.

[Core.Log]
Online=Verbose
OnlineSession=Verbose
OnlineGame=Verbose
LogEOSCoreSubsystem=Verbose
LogEOSCore=Verbose

[OnlineSubsystem]
DefaultPlatformService=EOS

Launching Dedicated Server

We’ll use Commandline arguments to authenticate and launch our server, the example below will authenticate our server using a local DeviceID, this is the minimum authentication required to communicate with Epic Online Services. The –EOSConfig= is optional, for example if you’re using a different configuration for your Server.

D:\WindowsServer\EOS_DedicatedServer.exe -server -log -AUTH_TYPE=deviceid -AUTH_LOGIN=test -AUTH_TOKEN=test -EOSConfig=ServerConfig

Listing our Server

You can use the default Session nodes to list a Dedicated Server. We’ll use the GameInstance in this example.

This will List your dedicated server as a joinable session.