Network Client

This guide shows how to configure the NetworkClient in your game.

NetworkClient Component

Class

NetworkClient is the entry point of your game to interact with the SocketWeaver backend services. You must have one and only one NetworkClient active in your Scene.

It is recommended to add the NetworkClient component to a separate GameObject in your scene. NetworkClient will automatically prevent the GameObject from being destroyed between Scenes.

Setup

1: Click Add Component and search for "NetworkClient"

2: Copy and Paste your game's API key into the API_KEY text field.

Properties

Name

Function

Logging Level

Controls the logging of the SWNetwork SDK lower level code.

Error is the default setting.

Log File Path

Controls log output directory

API_KEY

The APIKEY of your game. It is generated in the SocketWeaver Developer Portal

Routing Info

SocketWeaver routes traffic based on the location of players.

The section below the API_KEY text field shows the routing information of a client.

The first line "f6921e3a..." is the playerId.

Lifecycle

Last updated