示例#1
0
    CommandCallbackType ReceiveCrusadeTeamNumListHandle(byte[] dataBuffer, int socketID)
    {
        SMsgEctypeTeamNum_SC sMsgEctypeTeamNum_SC = SMsgEctypeTeamNum_SC.ParsePackage(dataBuffer);

        TraceUtil.Log(SystemModel.Lee, TraceLevel.Verbose, "sMsgEctypeTeamNum_SC : " + sMsgEctypeTeamNum_SC.byEctypeNum);
        UIEventManager.Instance.TriggerUIEvent(UIEventType.EctypeTeamNum, sMsgEctypeTeamNum_SC);
        return(CommandCallbackType.Continue);
    }
示例#2
0
        void UpdateEctypeTeamNumHandle(object obj)
        {
            SMsgEctypeTeamNum_SC sMsgEctypeTeamNum_SC = (SMsgEctypeTeamNum_SC)obj;

            sMsgEctypeTeamNum_SC.sTeamNumContext.ApplyAllItem(p => {
                if (m_ectypeItemList.ContainsKey(p.dwEctypeID))
                {
                    m_ectypeItemList[p.dwEctypeID].UpdateTeamNum(p.byTeamNum);
                }
            });
        }
示例#3
0
    public static SMsgEctypeTeamNum_SC ParsePackage(byte[] dataBuffer)
    {
        SMsgEctypeTeamNum_SC sMsgEctypeTeamNum_SC = new SMsgEctypeTeamNum_SC();
        int of = 0;

        of += PackageHelper.ReadData(dataBuffer.Skip(of).ToArray(), out sMsgEctypeTeamNum_SC.byEctypeNum);
        sMsgEctypeTeamNum_SC.sTeamNumContext = new STeamNumContext[sMsgEctypeTeamNum_SC.byEctypeNum];
        for (int i = 0; i < sMsgEctypeTeamNum_SC.byEctypeNum; i++)
        {
            sMsgEctypeTeamNum_SC.sTeamNumContext[i] = new STeamNumContext();
            of += PackageHelper.ReadData(dataBuffer.Skip(of).ToArray(), out sMsgEctypeTeamNum_SC.sTeamNumContext[i].dwEctypeID);
            of += PackageHelper.ReadData(dataBuffer.Skip(of).ToArray(), out sMsgEctypeTeamNum_SC.sTeamNumContext[i].byTeamNum);
        }
        return(sMsgEctypeTeamNum_SC);
    }