Esempio n. 1
0
    /// <summary>
    /// 读取字节流(完整版)
    /// </summary>
    protected override void toReadBytesFull(BytesReadStream stream)
    {
        base.toReadBytesFull(stream);

        stream.startReadObj();

        BaseData dataT = stream.readDataFullNotNull();

        if (dataT != null)
        {
            if (dataT is PlayerApplyRoleGroupSelfData)
            {
                this.data = (PlayerApplyRoleGroupSelfData)dataT;
            }
            else
            {
                this.data = new PlayerApplyRoleGroupSelfData();
                if (!(dataT.GetType().IsAssignableFrom(typeof(PlayerApplyRoleGroupSelfData))))
                {
                    stream.throwTypeReadError(typeof(PlayerApplyRoleGroupSelfData), dataT.GetType());
                }
                this.data.shadowCopy(dataT);
            }
        }
        else
        {
            this.data = null;
        }

        stream.endReadObj();
    }
Esempio n. 2
0
    /** 申请处理结果 */
    public void onApplyResult(long groupID, int result)
    {
        PlayerApplyRoleGroupSelfData aData = _d.applyDic.get(groupID);

        if (aData == null)
        {
            me.warnLog("收到申请处理结果时,未找到数据", groupID);
            return;
        }

        //标记结果
        aData.result = result;

        if (result == RoleGroupHandleResultType.Refuse)
        {
            aData.disableTime = aData.time + _config.refuseApplyTime * 1000;
        }
        else
        {
            _d.applyDic.remove(groupID);
        }

        me.dispatch(GameEventType.RoleGroupSelfApplyChange, evt);

        if (BaseC.constlist.roleGroupHandleResult_needReback(result))
        {
            evt.groupID = groupID;

            me.dispatch(GameEventType.RoleGroupSelfApplyResult, evt);
        }
    }
    /// <summary>
    /// 复制(深拷贝)
    /// </summary>
    protected override void toCopy(BaseData data)
    {
        if (!(data is PlayerApplyRoleGroupSelfData))
        {
            return;
        }

        PlayerApplyRoleGroupSelfData mData = (PlayerApplyRoleGroupSelfData)data;

        if (mData.data != null)
        {
            this.data = (RoleGroupSimpleData)mData.data.clone();
        }
        else
        {
            this.data = null;
            nullObjError("data");
        }

        this.time = mData.time;

        this.result = mData.result;

        this.disableTime = mData.disableTime;
    }
Esempio n. 4
0
    /** 添加申请玩家群数据到自身 */
    public void onAddApplySelf(PlayerApplyRoleGroupSelfData selfData)
    {
        _d.applyDic.put(selfData.data.groupID, selfData);

        evt.groupID = selfData.data.groupID;

        me.dispatch(GameEventType.RoleGroupSelfApplyChange, evt);
    }
    /// <summary>
    /// 复制(潜拷贝)
    /// </summary>
    protected override void toShadowCopy(BaseData data)
    {
        if (!(data is PlayerApplyRoleGroupSelfData))
        {
            return;
        }

        PlayerApplyRoleGroupSelfData mData = (PlayerApplyRoleGroupSelfData)data;

        this.data        = mData.data;
        this.time        = mData.time;
        this.result      = mData.result;
        this.disableTime = mData.disableTime;
    }
Esempio n. 6
0
    /** 申请加入玩家群 */
    public void applyRoleGroup(long groupID)
    {
        if (!_config.canApply)
        {
            me.warnLog("申请加入玩家群时,配置不可申请");
            return;
        }

        if (isRoleGroupFull())
        {
            me.warnLog("申请加入玩家群时,群数已满");
            return;
        }

        PlayerRoleGroup roleGroup = getRoleGroup(groupID);

        if (roleGroup != null)
        {
            me.warnLog("申请加入玩家群时,已在该群");
            return;
        }

        if (!me.role.checkRoleConditions(_config.joinConditions, true))
        {
            me.warnLog("申请加入玩家群时,自身条件不满足");
            return;
        }

        PlayerApplyRoleGroupSelfData aData = _d.applyDic.get(groupID);

        if (aData != null)
        {
            me.warnLog("申请加入玩家群时,已申请过");
            return;
        }

        if (_config.applyKeepMax > 0 && _d.applyDic.size() >= _config.applyKeepMax)
        {
            me.warnLog("申请加入玩家群时,已达到申请上限");
            return;
        }


        me.send(FuncApplyRoleGroupRequest.create(_funcID, groupID));
    }
    /// <summary>
    /// 是否数据一致
    /// </summary>
    protected override bool toDataEquals(BaseData data)
    {
        PlayerApplyRoleGroupSelfData mData = (PlayerApplyRoleGroupSelfData)data;

        if (mData.data != null)
        {
            if (this.data == null)
            {
                return(false);
            }
            if (!this.data.dataEquals(mData.data))
            {
                return(false);
            }
        }
        else
        {
            if (this.data != null)
            {
                return(false);
            }
        }

        if (this.time != mData.time)
        {
            return(false);
        }

        if (this.result != mData.result)
        {
            return(false);
        }

        if (this.disableTime != mData.disableTime)
        {
            return(false);
        }

        return(true);
    }
Esempio n. 8
0
    /// <summary>
    /// 读取字节流(简版)
    /// </summary>
    protected override void toReadBytesSimple(BytesReadStream stream)
    {
        base.toReadBytesSimple(stream);

        this.data = (PlayerApplyRoleGroupSelfData)stream.readDataSimpleNotNull();
    }
Esempio n. 9
0
    /// <summary>
    /// 回池
    /// </summary>
    protected override void toRelease(DataPool pool)
    {
        base.toRelease(pool);

        this.data = null;
    }
    /// <summary>
    /// 转文本输出
    /// </summary>
    protected override void toWriteDataString(DataWriter writer)
    {
        base.toWriteDataString(writer);

        writer.writeTabs();
        writer.sb.Append("groups");
        writer.sb.Append(':');
        writer.sb.Append("Map<long,PlayerRoleGroupData>");
        if (this.groups != null)
        {
            writer.sb.Append('(');
            writer.sb.Append(this.groups.size());
            writer.sb.Append(')');
            writer.writeEnter();
            writer.writeLeftBrace();
            if (!this.groups.isEmpty())
            {
                long   groupsKFreeValue             = this.groups.getFreeValue();
                long[] groupsKKeys                  = this.groups.getKeys();
                PlayerRoleGroupData[] groupsVValues = this.groups.getValues();
                for (int groupsKI = groupsKKeys.Length - 1; groupsKI >= 0; --groupsKI)
                {
                    long groupsK = groupsKKeys[groupsKI];
                    if (groupsK != groupsKFreeValue)
                    {
                        PlayerRoleGroupData groupsV = groupsVValues[groupsKI];
                        writer.writeTabs();
                        writer.sb.Append(groupsK);

                        writer.sb.Append(':');
                        if (groupsV != null)
                        {
                            groupsV.writeDataString(writer);
                        }
                        else
                        {
                            writer.sb.Append("PlayerRoleGroupData=null");
                        }

                        writer.writeEnter();
                    }
                }
            }
            writer.writeRightBrace();
        }
        else
        {
            writer.sb.Append("=null");
        }

        writer.writeEnter();
        writer.writeTabs();
        writer.sb.Append("applyDic");
        writer.sb.Append(':');
        writer.sb.Append("Map<long,PlayerApplyRoleGroupSelfData>");
        if (this.applyDic != null)
        {
            writer.sb.Append('(');
            writer.sb.Append(this.applyDic.size());
            writer.sb.Append(')');
            writer.writeEnter();
            writer.writeLeftBrace();
            if (!this.applyDic.isEmpty())
            {
                long   applyDicKFreeValue = this.applyDic.getFreeValue();
                long[] applyDicKKeys      = this.applyDic.getKeys();
                PlayerApplyRoleGroupSelfData[] applyDicVValues = this.applyDic.getValues();
                for (int applyDicKI = applyDicKKeys.Length - 1; applyDicKI >= 0; --applyDicKI)
                {
                    long applyDicK = applyDicKKeys[applyDicKI];
                    if (applyDicK != applyDicKFreeValue)
                    {
                        PlayerApplyRoleGroupSelfData applyDicV = applyDicVValues[applyDicKI];
                        writer.writeTabs();
                        writer.sb.Append(applyDicK);

                        writer.sb.Append(':');
                        if (applyDicV != null)
                        {
                            applyDicV.writeDataString(writer);
                        }
                        else
                        {
                            writer.sb.Append("PlayerApplyRoleGroupSelfData=null");
                        }

                        writer.writeEnter();
                    }
                }
            }
            writer.writeRightBrace();
        }
        else
        {
            writer.sb.Append("=null");
        }

        writer.writeEnter();
        writer.writeTabs();
        writer.sb.Append("canInviteInAbs");
        writer.sb.Append(':');
        writer.sb.Append(this.canInviteInAbs);

        writer.writeEnter();
        writer.writeTabs();
        writer.sb.Append("inviteList");
        writer.sb.Append(':');
        writer.sb.Append("List<InviteRoleGroupReceiveData>");
        if (this.inviteList != null)
        {
            SList <InviteRoleGroupReceiveData> inviteListT = this.inviteList;
            int inviteListLen = inviteListT.size();
            writer.sb.Append('(');
            writer.sb.Append(inviteListLen);
            writer.sb.Append(')');
            writer.writeEnter();
            writer.writeLeftBrace();
            for (int inviteListI = 0; inviteListI < inviteListLen; ++inviteListI)
            {
                InviteRoleGroupReceiveData inviteListV = inviteListT.get(inviteListI);
                writer.writeTabs();
                writer.sb.Append(inviteListI);
                writer.sb.Append(':');
                if (inviteListV != null)
                {
                    inviteListV.writeDataString(writer);
                }
                else
                {
                    writer.sb.Append("InviteRoleGroupReceiveData=null");
                }

                writer.writeEnter();
            }
            writer.writeRightBrace();
        }
        else
        {
            writer.sb.Append("=null");
        }

        writer.writeEnter();
    }
    /// <summary>
    /// 是否数据一致
    /// </summary>
    protected override bool toDataEquals(BaseData data)
    {
        if (!base.toDataEquals(data))
        {
            return(false);
        }

        PlayerRoleGroupClientToolData mData = (PlayerRoleGroupClientToolData)data;

        if (mData.groups != null)
        {
            if (this.groups == null)
            {
                return(false);
            }
            if (this.groups.size() != mData.groups.size())
            {
                return(false);
            }
            LongObjectMap <PlayerRoleGroupData> groupsR = mData.groups;
            if (!this.groups.isEmpty())
            {
                long   groupsKFreeValue             = this.groups.getFreeValue();
                long[] groupsKKeys                  = this.groups.getKeys();
                PlayerRoleGroupData[] groupsVValues = this.groups.getValues();
                for (int groupsKI = groupsKKeys.Length - 1; groupsKI >= 0; --groupsKI)
                {
                    long groupsK = groupsKKeys[groupsKI];
                    if (groupsK != groupsKFreeValue)
                    {
                        PlayerRoleGroupData groupsV = groupsVValues[groupsKI];
                        PlayerRoleGroupData groupsU = groupsR.get(groupsK);
                        if (groupsU != null)
                        {
                            if (groupsV == null)
                            {
                                return(false);
                            }
                            if (!groupsV.dataEquals(groupsU))
                            {
                                return(false);
                            }
                        }
                        else
                        {
                            if (groupsV != null)
                            {
                                return(false);
                            }
                        }
                    }
                }
            }
        }
        else
        {
            if (this.groups != null)
            {
                return(false);
            }
        }

        if (mData.applyDic != null)
        {
            if (this.applyDic == null)
            {
                return(false);
            }
            if (this.applyDic.size() != mData.applyDic.size())
            {
                return(false);
            }
            LongObjectMap <PlayerApplyRoleGroupSelfData> applyDicR = mData.applyDic;
            if (!this.applyDic.isEmpty())
            {
                long   applyDicKFreeValue = this.applyDic.getFreeValue();
                long[] applyDicKKeys      = this.applyDic.getKeys();
                PlayerApplyRoleGroupSelfData[] applyDicVValues = this.applyDic.getValues();
                for (int applyDicKI = applyDicKKeys.Length - 1; applyDicKI >= 0; --applyDicKI)
                {
                    long applyDicK = applyDicKKeys[applyDicKI];
                    if (applyDicK != applyDicKFreeValue)
                    {
                        PlayerApplyRoleGroupSelfData applyDicV = applyDicVValues[applyDicKI];
                        PlayerApplyRoleGroupSelfData applyDicU = applyDicR.get(applyDicK);
                        if (applyDicU != null)
                        {
                            if (applyDicV == null)
                            {
                                return(false);
                            }
                            if (!applyDicV.dataEquals(applyDicU))
                            {
                                return(false);
                            }
                        }
                        else
                        {
                            if (applyDicV != null)
                            {
                                return(false);
                            }
                        }
                    }
                }
            }
        }
        else
        {
            if (this.applyDic != null)
            {
                return(false);
            }
        }

        if (this.canInviteInAbs != mData.canInviteInAbs)
        {
            return(false);
        }

        if (mData.inviteList != null)
        {
            if (this.inviteList == null)
            {
                return(false);
            }
            if (this.inviteList.size() != mData.inviteList.size())
            {
                return(false);
            }
            SList <InviteRoleGroupReceiveData> inviteListT = this.inviteList;
            SList <InviteRoleGroupReceiveData> inviteListR = mData.inviteList;
            int inviteListLen = inviteListT.size();
            for (int inviteListI = 0; inviteListI < inviteListLen; ++inviteListI)
            {
                InviteRoleGroupReceiveData inviteListU = inviteListT.get(inviteListI);
                InviteRoleGroupReceiveData inviteListV = inviteListR.get(inviteListI);
                if (inviteListV != null)
                {
                    if (inviteListU == null)
                    {
                        return(false);
                    }
                    if (!inviteListU.dataEquals(inviteListV))
                    {
                        return(false);
                    }
                }
                else
                {
                    if (inviteListU != null)
                    {
                        return(false);
                    }
                }
            }
        }
        else
        {
            if (this.inviteList != null)
            {
                return(false);
            }
        }

        return(true);
    }
    /// <summary>
    /// 读取字节流(完整版)
    /// </summary>
    protected override void toReadBytesFull(BytesReadStream stream)
    {
        base.toReadBytesFull(stream);

        stream.startReadObj();

        int groupsLen = stream.readLen();

        if (this.groups != null)
        {
            this.groups.clear();
            this.groups.ensureCapacity(groupsLen);
        }
        else
        {
            this.groups = new LongObjectMap <PlayerRoleGroupData>(groupsLen);
        }

        LongObjectMap <PlayerRoleGroupData> groupsT = this.groups;

        for (int groupsI = groupsLen - 1; groupsI >= 0; --groupsI)
        {
            PlayerRoleGroupData groupsV;
            BaseData            groupsVT = stream.readDataFullNotNull();
            if (groupsVT != null)
            {
                if (groupsVT is PlayerRoleGroupData)
                {
                    groupsV = (PlayerRoleGroupData)groupsVT;
                }
                else
                {
                    groupsV = new PlayerRoleGroupData();
                    if (!(groupsVT.GetType().IsAssignableFrom(typeof(PlayerRoleGroupData))))
                    {
                        stream.throwTypeReadError(typeof(PlayerRoleGroupData), groupsVT.GetType());
                    }
                    groupsV.shadowCopy(groupsVT);
                }
            }
            else
            {
                groupsV = null;
            }

            groupsT.put(groupsV.groupID, groupsV);
        }

        int applyDicLen = stream.readLen();

        if (this.applyDic != null)
        {
            this.applyDic.clear();
            this.applyDic.ensureCapacity(applyDicLen);
        }
        else
        {
            this.applyDic = new LongObjectMap <PlayerApplyRoleGroupSelfData>(applyDicLen);
        }

        LongObjectMap <PlayerApplyRoleGroupSelfData> applyDicT = this.applyDic;

        for (int applyDicI = applyDicLen - 1; applyDicI >= 0; --applyDicI)
        {
            PlayerApplyRoleGroupSelfData applyDicV;
            BaseData applyDicVT = stream.readDataFullNotNull();
            if (applyDicVT != null)
            {
                if (applyDicVT is PlayerApplyRoleGroupSelfData)
                {
                    applyDicV = (PlayerApplyRoleGroupSelfData)applyDicVT;
                }
                else
                {
                    applyDicV = new PlayerApplyRoleGroupSelfData();
                    if (!(applyDicVT.GetType().IsAssignableFrom(typeof(PlayerApplyRoleGroupSelfData))))
                    {
                        stream.throwTypeReadError(typeof(PlayerApplyRoleGroupSelfData), applyDicVT.GetType());
                    }
                    applyDicV.shadowCopy(applyDicVT);
                }
            }
            else
            {
                applyDicV = null;
            }

            applyDicT.put(applyDicV.data.groupID, applyDicV);
        }

        this.canInviteInAbs = stream.readBoolean();

        int inviteListLen = stream.readLen();

        if (this.inviteList != null)
        {
            this.inviteList.clear();
            this.inviteList.ensureCapacity(inviteListLen);
        }
        else
        {
            this.inviteList = new SList <InviteRoleGroupReceiveData>();
        }

        SList <InviteRoleGroupReceiveData> inviteListT = this.inviteList;

        for (int inviteListI = inviteListLen - 1; inviteListI >= 0; --inviteListI)
        {
            InviteRoleGroupReceiveData inviteListV;
            BaseData inviteListVT = stream.readDataFullNotNull();
            if (inviteListVT != null)
            {
                if (inviteListVT is InviteRoleGroupReceiveData)
                {
                    inviteListV = (InviteRoleGroupReceiveData)inviteListVT;
                }
                else
                {
                    inviteListV = new InviteRoleGroupReceiveData();
                    if (!(inviteListVT.GetType().IsAssignableFrom(typeof(InviteRoleGroupReceiveData))))
                    {
                        stream.throwTypeReadError(typeof(InviteRoleGroupReceiveData), inviteListVT.GetType());
                    }
                    inviteListV.shadowCopy(inviteListVT);
                }
            }
            else
            {
                inviteListV = null;
            }

            inviteListT.add(inviteListV);
        }

        stream.endReadObj();
    }
    /// <summary>
    /// 复制(深拷贝)
    /// </summary>
    protected override void toCopy(BaseData data)
    {
        base.toCopy(data);

        if (!(data is PlayerRoleGroupClientToolData))
        {
            return;
        }

        PlayerRoleGroupClientToolData mData = (PlayerRoleGroupClientToolData)data;

        if (mData.groups != null)
        {
            if (this.groups != null)
            {
                this.groups.clear();
                this.groups.ensureCapacity(mData.groups.size());
            }
            else
            {
                this.groups = new LongObjectMap <PlayerRoleGroupData>(mData.groups.size());
            }

            LongObjectMap <PlayerRoleGroupData> groupsT = this.groups;
            if (!mData.groups.isEmpty())
            {
                PlayerRoleGroupData[] groupsVValues = mData.groups.getValues();
                for (int groupsVI = groupsVValues.Length - 1; groupsVI >= 0; --groupsVI)
                {
                    PlayerRoleGroupData groupsV = groupsVValues[groupsVI];
                    if (groupsV != null)
                    {
                        PlayerRoleGroupData groupsU;
                        if (groupsV != null)
                        {
                            groupsU = (PlayerRoleGroupData)groupsV.clone();
                        }
                        else
                        {
                            groupsU = null;
                            nullObjError("groupsU");
                        }

                        groupsT.put(groupsU.groupID, groupsU);
                    }
                }
            }
        }
        else
        {
            this.groups = null;
            nullObjError("groups");
        }

        if (mData.applyDic != null)
        {
            if (this.applyDic != null)
            {
                this.applyDic.clear();
                this.applyDic.ensureCapacity(mData.applyDic.size());
            }
            else
            {
                this.applyDic = new LongObjectMap <PlayerApplyRoleGroupSelfData>(mData.applyDic.size());
            }

            LongObjectMap <PlayerApplyRoleGroupSelfData> applyDicT = this.applyDic;
            if (!mData.applyDic.isEmpty())
            {
                PlayerApplyRoleGroupSelfData[] applyDicVValues = mData.applyDic.getValues();
                for (int applyDicVI = applyDicVValues.Length - 1; applyDicVI >= 0; --applyDicVI)
                {
                    PlayerApplyRoleGroupSelfData applyDicV = applyDicVValues[applyDicVI];
                    if (applyDicV != null)
                    {
                        PlayerApplyRoleGroupSelfData applyDicU;
                        if (applyDicV != null)
                        {
                            applyDicU = (PlayerApplyRoleGroupSelfData)applyDicV.clone();
                        }
                        else
                        {
                            applyDicU = null;
                            nullObjError("applyDicU");
                        }

                        applyDicT.put(applyDicU.data.groupID, applyDicU);
                    }
                }
            }
        }
        else
        {
            this.applyDic = null;
            nullObjError("applyDic");
        }

        this.canInviteInAbs = mData.canInviteInAbs;

        if (mData.inviteList != null)
        {
            if (this.inviteList != null)
            {
                this.inviteList.clear();
                this.inviteList.ensureCapacity(mData.inviteList.size());
            }
            else
            {
                this.inviteList = new SList <InviteRoleGroupReceiveData>();
            }

            SList <InviteRoleGroupReceiveData> inviteListT = this.inviteList;
            if (!mData.inviteList.isEmpty())
            {
                InviteRoleGroupReceiveData[] inviteListVValues = mData.inviteList.getValues();
                for (int inviteListVI = 0, inviteListVLen = mData.inviteList.length(); inviteListVI < inviteListVLen; ++inviteListVI)
                {
                    InviteRoleGroupReceiveData inviteListV = inviteListVValues[inviteListVI];
                    InviteRoleGroupReceiveData inviteListU;
                    if (inviteListV != null)
                    {
                        inviteListU = (InviteRoleGroupReceiveData)inviteListV.clone();
                    }
                    else
                    {
                        inviteListU = null;
                        nullObjError("inviteListU");
                    }

                    inviteListT.add(inviteListU);
                }
            }
        }
        else
        {
            this.inviteList = null;
            nullObjError("inviteList");
        }
    }
    /// <summary>
    /// 写入字节流(简版)
    /// </summary>
    protected override void toWriteBytesSimple(BytesWriteStream stream)
    {
        base.toWriteBytesSimple(stream);

        if (this.groups != null)
        {
            stream.writeLen(this.groups.size());
            if (!this.groups.isEmpty())
            {
                PlayerRoleGroupData[] groupsVValues = this.groups.getValues();
                for (int groupsVI = groupsVValues.Length - 1; groupsVI >= 0; --groupsVI)
                {
                    PlayerRoleGroupData groupsV = groupsVValues[groupsVI];
                    if (groupsV != null)
                    {
                        if (groupsV != null)
                        {
                            stream.writeDataSimpleNotNull(groupsV);
                        }
                        else
                        {
                            nullObjError("groupsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("groups");
        }

        if (this.applyDic != null)
        {
            stream.writeLen(this.applyDic.size());
            if (!this.applyDic.isEmpty())
            {
                PlayerApplyRoleGroupSelfData[] applyDicVValues = this.applyDic.getValues();
                for (int applyDicVI = applyDicVValues.Length - 1; applyDicVI >= 0; --applyDicVI)
                {
                    PlayerApplyRoleGroupSelfData applyDicV = applyDicVValues[applyDicVI];
                    if (applyDicV != null)
                    {
                        if (applyDicV != null)
                        {
                            stream.writeDataSimpleNotNull(applyDicV);
                        }
                        else
                        {
                            nullObjError("applyDicV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("applyDic");
        }

        stream.writeBoolean(this.canInviteInAbs);

        if (this.inviteList != null)
        {
            stream.writeLen(this.inviteList.size());
            if (!this.inviteList.isEmpty())
            {
                InviteRoleGroupReceiveData[] inviteListVValues = this.inviteList.getValues();
                for (int inviteListVI = 0, inviteListVLen = this.inviteList.length(); inviteListVI < inviteListVLen; ++inviteListVI)
                {
                    InviteRoleGroupReceiveData inviteListV = inviteListVValues[inviteListVI];
                    if (inviteListV != null)
                    {
                        stream.writeDataSimpleNotNull(inviteListV);
                    }
                    else
                    {
                        nullObjError("inviteListV");
                    }
                }
            }
        }
        else
        {
            nullObjError("inviteList");
        }
    }
Esempio n. 15
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        base.toWriteBytesFull(stream);

        stream.startWriteObj();

        if (this.groups != null)
        {
            stream.writeLen(this.groups.size());
            if (!this.groups.isEmpty())
            {
                PlayerRoleGroupSaveData[] groupsVValues = this.groups.getValues();
                for (int groupsVI = groupsVValues.Length - 1; groupsVI >= 0; --groupsVI)
                {
                    PlayerRoleGroupSaveData groupsV = groupsVValues[groupsVI];
                    if (groupsV != null)
                    {
                        if (groupsV != null)
                        {
                            stream.writeDataFullNotNull(groupsV);
                        }
                        else
                        {
                            nullObjError("groupsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("groups");
        }

        stream.writeInt(this.operateNum);

        if (this.applyDic != null)
        {
            stream.writeLen(this.applyDic.size());
            if (!this.applyDic.isEmpty())
            {
                PlayerApplyRoleGroupSelfData[] applyDicVValues = this.applyDic.getValues();
                for (int applyDicVI = applyDicVValues.Length - 1; applyDicVI >= 0; --applyDicVI)
                {
                    PlayerApplyRoleGroupSelfData applyDicV = applyDicVValues[applyDicVI];
                    if (applyDicV != null)
                    {
                        if (applyDicV != null)
                        {
                            stream.writeDataFullNotNull(applyDicV);
                        }
                        else
                        {
                            nullObjError("applyDicV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("applyDic");
        }

        stream.writeBoolean(this.canInviteInAbs);

        if (this.createOperateNums != null)
        {
            stream.writeLen(this.createOperateNums.size());
            if (!this.createOperateNums.isEmpty())
            {
                long[] createOperateNumsVValues = this.createOperateNums.getValues();
                int    createOperateNumsVMark   = this.createOperateNums.getMark();
                int    createOperateNumsVStart  = this.createOperateNums.getStart();
                for (int createOperateNumsVI = 0, createOperateNumsVLen = this.createOperateNums.length(); createOperateNumsVI < createOperateNumsVLen; ++createOperateNumsVI)
                {
                    long createOperateNumsV = createOperateNumsVValues[(createOperateNumsVI + createOperateNumsVStart) & createOperateNumsVMark];
                    stream.writeLong(createOperateNumsV);
                }
            }
        }
        else
        {
            nullObjError("createOperateNums");
        }

        if (this.inviteList != null)
        {
            stream.writeLen(this.inviteList.size());
            if (!this.inviteList.isEmpty())
            {
                InviteRoleGroupReceiveData[] inviteListVValues = this.inviteList.getValues();
                for (int inviteListVI = 0, inviteListVLen = this.inviteList.length(); inviteListVI < inviteListVLen; ++inviteListVI)
                {
                    InviteRoleGroupReceiveData inviteListV = inviteListVValues[inviteListVI];
                    if (inviteListV != null)
                    {
                        stream.writeDataFullNotNull(inviteListV);
                    }
                    else
                    {
                        nullObjError("inviteListV");
                    }
                }
            }
        }
        else
        {
            nullObjError("inviteList");
        }

        stream.endWriteObj();
    }