当前位置: 首页>>代码示例>>C#>>正文


C# MemoryStream.readBlob方法代码示例

本文整理汇总了C#中KBEngine.MemoryStream.readBlob方法的典型用法代码示例。如果您正苦于以下问题:C# MemoryStream.readBlob方法的具体用法?C# MemoryStream.readBlob怎么用?C# MemoryStream.readBlob使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在KBEngine.MemoryStream的用法示例。


在下文中一共展示了MemoryStream.readBlob方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Client_onLoginSuccessfully

        /*
            登录loginapp成功了
        */
        public void Client_onLoginSuccessfully(MemoryStream stream)
        {
            var accountName = stream.readString();
            username = accountName;
            baseappIP = stream.readString();
            baseappPort = stream.readUint16();

            Dbg.DEBUG_MSG("KBEngine::Client_onLoginSuccessfully: accountName(" + accountName + "), addr(" +
                    baseappIP + ":" + baseappPort + "), datas(" + _serverdatas.Length + ")!");

            _serverdatas = stream.readBlob();
            login_baseapp(true);
        }
开发者ID:buckyu,项目名称:kbengine_unity3d_plugins,代码行数:16,代码来源:KBEngine.cs

示例2: Client_onLoginFailed

 /*
     登录loginapp失败了
 */
 public void Client_onLoginFailed(MemoryStream stream)
 {
     UInt16 failedcode = stream.readUint16();
     _serverdatas = stream.readBlob();
     Dbg.ERROR_MSG("KBEngine::Client_onLoginFailed: failedcode(" + failedcode + "), datas(" + _serverdatas.Length + ")!");
     Event.fireAll("onLoginFailed", new object[]{failedcode});
 }
开发者ID:buckyu,项目名称:kbengine_unity3d_plugins,代码行数:10,代码来源:KBEngine.cs

示例3: Client_onCreateAccountResult

        /*
            账号创建返回结果
        */
        public void Client_onCreateAccountResult(MemoryStream stream)
        {
            UInt16 retcode = stream.readUint16();
            byte[] datas = stream.readBlob();

            Event.fireOut("onCreateAccountResult", new object[]{retcode, datas});

            if(retcode != 0)
            {
                Dbg.WARNING_MSG("KBEngine::Client_onCreateAccountResult: " + username + " create is failed! code=" + retcode + "!");
                return;
            }

            Dbg.DEBUG_MSG("KBEngine::Client_onCreateAccountResult: " + username + " create is successfully!");
        }
开发者ID:buckyu,项目名称:kbengine_unity3d_plugins,代码行数:18,代码来源:KBEngine.cs

示例4: onImportServerErrorsDescr

        /*
            服务端错误描述导入了
        */
        public void onImportServerErrorsDescr(MemoryStream stream)
        {
            UInt16 size = stream.readUint16();
            while(size > 0)
            {
                size -= 1;

                ServerErr e;
                e.id = stream.readUint16();
                e.name = System.Text.Encoding.UTF8.GetString(stream.readBlob());
                e.descr = System.Text.Encoding.UTF8.GetString(stream.readBlob());

                serverErrs.Add(e.id, e);

                //Dbg.DEBUG_MSG("Client_onImportServerErrorsDescr: id=" + e.id + ", name=" + e.name + ", descr=" + e.descr);
            }
        }
开发者ID:buckyu,项目名称:kbengine_unity3d_plugins,代码行数:20,代码来源:KBEngine.cs

示例5: createFromStream

		public override object createFromStream(MemoryStream stream)
		{
			return stream.readBlob();
		}
开发者ID:kjdjpan,项目名称:kbengine_unity3d_plugins,代码行数:4,代码来源:DataTypes.cs


注:本文中的KBEngine.MemoryStream.readBlob方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。