我引用https://socket.io/blog/socket-io-cpp/上提供的示例来创建一个Socket.IO客户端。我得到了错误 1>c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.16.27023\includeerror C2338: tuple index out of bounds
1>c:\program files (x86)\m
我在两个viewControllers VC1和VC2上连接套接字。当我在VC1时一切正常工作,回调正常工作。当我按VC2并返回到VC1时,套接字回调将出现在VC2上。但当时我的presentViewController是VC1。可能是我的套接字库老了,所以[self.socket removeAllHandlers]; is not working
通过在VC的viewDidLoad中发布通知,我设法让VC从套接字中填充数据,但这似乎不是正确的做法。我的应用程序是如何工作的,我向套接字发出数据,套接字发出一个名为“初始化”的调用,在这个通知中,我推送到一个新的VC。这可能是造成问题的原因吗?) {
//Send a message to RoomCode controler to notify the reciever[self.socket