Humanoid Control for Unity v4
Public Types | Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
Passer.NetworkingStarter Class Reference

Description

Setup and start of networking

To make a networked multiplayer environment you can use the Networking Starter component. It is still possible to use dedicated code and components for the chosen networking solution instead which will give you more control of the setup of the network.

The easiest way to turn a single-user scene in a multi-user environment is to add the NetworkingStarter prefab to the scene. You can find this in the Humanoid->Prefabs->Networking folder.

Inherits Photon.Pun.MonoBehaviourPunCallbackselse public class NetworkingStarter Photon.PunBehaviourendifelif hNW_BOLT public class NetworkingStarter Bolt.GlobalEventListenerelse public class NetworkingStarter MonoBehaviourendif.

Inherited by Passer.Humanoid.NetworkingSpawner.

Public Types

enum  ServerType { CloudServer , OwnServer }
 Server types
 
enum  Role { Host , Client }
 Network Role
 

Public Member Functions

void StartHost ()
 Start local networking with Host role
 
void StartClient ()
 Start local networking with Client role
 
void StartClient (string roomName, int gameVersion)
 Start cloud networking with Client role
 
override void OnConnectedToMaster ()
 
override void OnJoinRoomFailed (short returnCode, string message) public override void OnPhotonJoinRoomFailed(object[] codeAndMsg)
 
override void OnJoinedRoom ()
 
override void BoltStartDone ()
 
override void SessionListUpdated (Map< Guid, UdpSession > sessionList)
 

Public Attributes

bool autoStart = true
 
string serverIpAddress = "127.0.0.1"
 The IP address of the host
 
string roomName = "default"
 The name of the environment shared by all the users
 
int gameVersion = 1
 The version of the environment shared by all the users
 
GameObject playerPrefab
 The player prefab which will be spawned across the network.
 
ServerType serverType
 The type of server used for the network
 
bool useRoleFile = false
 Enables the use of a role file which determines whether the application is a Host or a Client
 
string roleFileName = "Role.txt"
 The filename of the role file
 
Role role
 The Role of this application
 
int sendRate = 25
 The rate at which humanoid pose messages are sent More...
 

Protected Member Functions

virtual void Awake ()
 
virtual void Start ()
 

Protected Attributes

INetworkingStarter starter = new UnetStarter()
 

Properties

bool connected [getprotected set]
 Indication whether the application is connected to the network
 
bool connecting [getprotected set]
 Indication whether the application is trying to connect to the network
 

Member Data Documentation

◆ sendRate

int Passer.NetworkingStarter.sendRate = 25

The rate at which humanoid pose messages are sent

In messages per second


The documentation for this class was generated from the following file: