Ejemplo n.º 1
0
        public void SendTo <T>(long playerID, T proto)
        {
            long sessionID = ProxyManager.instance.GetProxy <PlayerProxy>().GetSessionID(playerID);

            byte[] data = ProtoTool.ToData(proto);
            SendTo(sessionID, data);
            Debug.Log("sendto ---> {0}   {1} :len({2})", playerID, proto.GetType(), data.Length);
        }
Ejemplo n.º 2
0
        public void Init()
        {
            DBManager.CreateInstance();
            ProtoTool.CreateInstance();
            ServerManager.CreateInstance();
            ProxyManager.CreateInstance();
            EventManager.CreateInstance();

            DBManager.instance.Init();
            ProtoTool.instance.Init();
            ServerManager.instance.Init();
            ProxyManager.instance.Init();

            TimerInit();
        }