少年修仙传客户端代码仓库
client_linchunjie
2018-08-23 522ca3468a56c88cb15eaa428eb7499d3dba386f
Core/GameEngine/DataToCtl/PackageRegedit.cs
@@ -11,11 +11,11 @@
    public static void Init()
    {
        // 登记相应的数据体及对应的数据转逻辑类
      Register(typeof(HAB04_tagMCBossRebornInfo), typeof(DTCAB04_tagMCBossRebornInfo));
      Register(typeof(HA40B_tagGCPlayerJoinFamilyWarInfo), typeof(DTCA40B_tagGCPlayerJoinFamilyWarInfo));
      Register(typeof(HA319_tagMCPackDownloadRecord), typeof(DTCA319_tagMCPackDownloadRecord));
        Register(typeof(HAC0A_tagGCMultiRealmPointInfo), typeof(DTCAC0A_tagGCMultiRealmPointInfo));
        Register(typeof(HAC08_tagGCBossRebornPoint), typeof(DTCAC08_tagGCBossRebornPoint));
      Register(typeof(HAC07_tagGCBossRebornInfo), typeof(DTCAC07_tagGCBossRebornInfo));
      Register(typeof(HAB03_tagMCBossRebornPlayerInfo), typeof(DTCAB03_tagMCBossRebornPlayerInfo));
      Register(typeof(HAA11_tagMCSpringSaleInfo), typeof(DTCAA11_tagMCSpringSaleInfo));
      Register(typeof(HAA10_tagMCCostRebatePlayerInfo), typeof(DTCAA10_tagMCCostRebatePlayerInfo));
@@ -366,6 +366,12 @@
        Register(typeof(HAA14_tagMCXJSDRecharge), typeof(DTCAA14_tagMCXJSDRecharge));
        Register(typeof(HAA15_tagMCAllPeoplePartyInfo), typeof(DTCAA15_tagMCAllPeoplePartyInfo));
        #endregion
        #region 神兽
        Register(typeof(HA3C0_tagMCDogzInfo), typeof(DTCA3C0_tagMCDogzInfo));
        Register(typeof(HA3C1_tagMCDogzHelpbattleState), typeof(DTCA3C1_tagMCDogzHelpbattleState));
        #endregion
    }
    private static void Register(Type _pack, Type _business)
@@ -374,7 +380,7 @@
        var businessInstance = _business.Assembly.CreateInstance(_business.Name) as DtcBasic;
        if (packToBusinessTable.ContainsKey(packInstance.cmd))
        {
            DesignDebug.LogFormat("重复封包登记: {0}!", _pack.Name);
            DebugEx.LogFormat("重复封包登记: {0}!", _pack.Name);
        }
        else
        {
@@ -396,7 +402,7 @@
        }
        catch (Exception ex)
        {
            DesignDebug.LogError(ex);
            DebugEx.LogError(ex);
        }
    }
@@ -444,7 +450,7 @@
        {
#if UNITY_EDITOR
            NetPkgCtl.AddNetPkg(vStr, NetPkgType.Server, string.Empty, string.Empty, null);
            DesignDebug.LogErrorFormat("C#层收到未登记的解包协议:{0},{1}", vCmdBytes[0].ToString("x2"), vCmdBytes[1].ToString("x2"));
            DebugEx.LogErrorFormat("C#层收到未登记的解包协议:{0},{1}", vCmdBytes[0].ToString("x2"), vCmdBytes[1].ToString("x2"));
#endif
        }
        return null;
@@ -467,7 +473,7 @@
        }
        else
        {
            DesignDebug.LogError("收到未定义的解包协议:" + vBytes[0].ToString("x2").ToUpper() + "," + vBytes[1].ToString("x2").ToUpper());
            DebugEx.LogError("收到未定义的解包协议:" + vBytes[0].ToString("x2").ToUpper() + "," + vBytes[1].ToString("x2").ToUpper());
        }
        return vNetPackInst;
    }