uZone usage
uZone uses simple configuration files to determine how things like listening ports, game servers and so on. These configuration files uses Erlang syntax, where lists are denoted by the use of [], tuples use {} and there is something called atoms. Atoms are reminiscent of enums from other languages, they are written with a leading lower case character. Look further down for an example.
uZone Master
To start the uZone master, you should first edit the accompanying file uz_server.cfg to set the port of inbound connections to the uZone master. After that is done, all you have to do is to run the start.bat file to start the master, or start.sh if you're on a Unix-like platform.
uZone Node
The node also has a configuration file that needs to be set, called uz_node.cfg. This config file contains two tuples of information, the first denoting where the uZone master can be found. Set the host and port appropriately here. The second tuple should contain a list of the local servers that can be started. A server is denoted by a tuple containing an identifying name with a leading lower case character and a second element containing a list of tuples. This list must contain the path tuple which denotes where the server executable can be found. It may also contain a flags tuple to denote command-line arguments to be given to the application at startup. See below for an example of this config file. To start the node run either start.bat or start.sh.
All game servers that runs on the node should also have the uZone dll imported to be able to communicate with the system. One game object should also have the uZoneMessenger and the uZoneInstance script components attached, that you can find in Plugins\uZone\Basic scripts.
uZone Interface
The uZone interface is needed both on the controlling end (probably a lobby server) and the game server end.To use the Unity interface for uZone, just import the dll file and run the functions InstanceManager.Subscribe(this.gameObject) followed by InstanceManager.Connect(host, port, id) to connect to the system and use the uZone API to start and stop servers as you want. Id is a unique identifier for the specific client connecting. It can be automatically assigned by setting it to an empty string. The calling object should have the uZoneMessenger component attached to it.






