So, this is the problem. I dont have a idea why this happen, and on the editor only this appears:
![alt text][1]
[1]: /storage/temp/52226-erro-unity.png
And this is the code that I'm using:
#pragma strict
import UnityEngine.Networking;
import UnityEngine.UI;
class NetworkManager_Custom extends NetworkManager
{
function IniciarServer()
{
definirPorta();
NetworkManager.singleton.StartHost();
}
function EntrarNoJogo() //ipe : String, port : int
{
definirIP();
definirPorta();
NetworkManager.singleton.StartClient();
}
function definirPorta()
{
NetworkManager.singleton.networkPort = 7777;
}
function definirIP()
{
NetworkManager.singleton.networkAddress = "localhost";
}
}
↧