Exemple #1
0
        public override void Start()
        {
            base.Start();

            FSPSession.ActiveTimeout = 10;//将超时时间设为10秒,以测试
            var fsp = new FSPManager();

            fsp.Init(port);

            var ipc = new IPCManager();

            ipc.Init(id);
            ipc.Start();

            m_context     = new ServerContext();
            m_context.fsp = fsp;
            m_context.ipc = ipc;

            GameManager.Instance.Init(m_context);

            ConsoleInput.onInputLine.AddListener(OnInputLine);
            ConsoleInput.onInputKey.AddListener(OnInputKey);
        }