Example #1
0
        public void Run(string username, string password, AppStarted callback)
        {
            appStarted = callback;
            Authentication auth = new Authentication();

            Authentication.Success success = AuthenticationSuccess;
            Authentication.Error   error   = AuthenticationError;

            StartCoroutine(auth.Authenticate(username, password, success, error));
        }
Example #2
0
        public void DoLogin()
        {
            User user = User.Instance;

            user.SetUser(NetworkSettings.instance.username.ToString(), NetworkSettings.instance.password.ToString());
            Authentication.Success success = OnAuthenticationSuccess;
            Authentication.Error   error   = OnAuthenticationError;

            app = gameObject.GetComponent <App>() as App;
            if (app == null)
            {
                app = gameObject.AddComponent <App>() as App;
            }

            if (NetworkSettings.instance.showClientStats)
            {
                app.showClientStats = true;
            }
            app.Login(NetworkSettings.instance.gameId, NetworkSettings.instance.httpHost, NetworkSettings.instance.httpPort, user.username, user.password, success, error);
        }
Example #3
0
        public void Login(string gameId, string hostname, int httpPort, string username, string password, Authentication.Success success, Authentication.Error error)
        {
            Authentication auth = new Authentication();

            StartCoroutine(auth.Authenticate(gameId, hostname, httpPort, username, password, success, error));
        }