Exemplo n.º 1
0
        public static string Receive()
        {
            UserLoginEvent log = JsonUtility.FromJson <UserLoginEvent>(FlowNetworkManager.reply);

            Config.userId      = log.user._id;
            Config.deviceId    = log.client._id;
            Config.projectList = log.projects;
            Config.loggedIn    = true;

            return("Receiving user login update: " + FlowNetworkManager.reply);
        }
Exemplo n.º 2
0
        public static string Receive()
        {
            UserLoginEvent log = JsonUtility.FromJson <UserLoginEvent>(FlowNetworkManager.reply);

            Config.userId      = log.user._id;
            Config.deviceId    = log.client._id;
            Config.projectList = log.projects;

            //Config.projectId = Config.projectList[0]._id;

            Debug.Log("received " + Config.projectList.Count + " projects from user " + Config.userId);
            foreach (FlowProject pid in Config.projectList)
            {
                Debug.Log(pid.projectName);
            }

            //For webclient
            Config.loggedIn = true;

            return("Receiving user login update: " + FlowNetworkManager.reply);
        }