Exemplo n.º 1
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        stream.startWriteObj();

        stream.writeInt(this.clientTaskInstanceIDIndex);

        if (this.accepts != null)
        {
            stream.writeLen(this.accepts.size());
            if (!this.accepts.isEmpty())
            {
                QuestData[] acceptsVValues = this.accepts.getValues();
                for (int acceptsVI = acceptsVValues.Length - 1; acceptsVI >= 0; --acceptsVI)
                {
                    QuestData acceptsV = acceptsVValues[acceptsVI];
                    if (acceptsV != null)
                    {
                        if (acceptsV != null)
                        {
                            stream.writeDataFullNotNull(acceptsV);
                        }
                        else
                        {
                            nullObjError("acceptsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("accepts");
        }

        if (this.completeLines != null)
        {
            stream.writeLen(this.completeLines.size());
            if (!this.completeLines.isEmpty())
            {
                int   completeLinesKFreeValue = this.completeLines.getFreeValue();
                int[] completeLinesKKeys      = this.completeLines.getKeys();
                int[] completeLinesVValues    = this.completeLines.getValues();
                for (int completeLinesKI = completeLinesKKeys.Length - 1; completeLinesKI >= 0; --completeLinesKI)
                {
                    int completeLinesK = completeLinesKKeys[completeLinesKI];
                    if (completeLinesK != completeLinesKFreeValue)
                    {
                        int completeLinesV = completeLinesVValues[completeLinesKI];
                        stream.writeInt(completeLinesK);

                        stream.writeInt(completeLinesV);
                    }
                }
            }
        }
        else
        {
            nullObjError("completeLines");
        }

        if (this.completeIDs != null)
        {
            stream.writeLen(this.completeIDs.size());
            if (!this.completeIDs.isEmpty())
            {
                int   completeIDsVFreeValue = this.completeIDs.getFreeValue();
                int[] completeIDsVKeys      = this.completeIDs.getKeys();
                for (int completeIDsVI = completeIDsVKeys.Length - 1; completeIDsVI >= 0; --completeIDsVI)
                {
                    int completeIDsV = completeIDsVKeys[completeIDsVI];
                    if (completeIDsV != completeIDsVFreeValue)
                    {
                        stream.writeInt(completeIDsV);
                    }
                }
            }
        }
        else
        {
            nullObjError("completeIDs");
        }

        if (this.completeQuestsDic != null)
        {
            stream.writeLen(this.completeQuestsDic.size());
            if (!this.completeQuestsDic.isEmpty())
            {
                QuestCompleteData[] completeQuestsDicVValues = this.completeQuestsDic.getValues();
                for (int completeQuestsDicVI = completeQuestsDicVValues.Length - 1; completeQuestsDicVI >= 0; --completeQuestsDicVI)
                {
                    QuestCompleteData completeQuestsDicV = completeQuestsDicVValues[completeQuestsDicVI];
                    if (completeQuestsDicV != null)
                    {
                        if (completeQuestsDicV != null)
                        {
                            stream.writeDataFullNotNull(completeQuestsDicV);
                        }
                        else
                        {
                            nullObjError("completeQuestsDicV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("completeQuestsDic");
        }

        stream.endWriteObj();
    }
Exemplo n.º 2
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        stream.startWriteObj();

        if (this.singleChannels != null)
        {
            stream.writeLen(this.singleChannels.size());
            if (!this.singleChannels.isEmpty())
            {
                int               singleChannelsKFreeValue = this.singleChannels.getFreeValue();
                int[]             singleChannelsKKeys      = this.singleChannels.getKeys();
                ChatChannelData[] singleChannelsVValues    = this.singleChannels.getValues();
                for (int singleChannelsKI = singleChannelsKKeys.Length - 1; singleChannelsKI >= 0; --singleChannelsKI)
                {
                    int singleChannelsK = singleChannelsKKeys[singleChannelsKI];
                    if (singleChannelsK != singleChannelsKFreeValue)
                    {
                        ChatChannelData singleChannelsV = singleChannelsVValues[singleChannelsKI];
                        stream.writeInt(singleChannelsK);

                        if (singleChannelsV != null)
                        {
                            stream.writeDataFullNotNull(singleChannelsV);
                        }
                        else
                        {
                            nullObjError("singleChannelsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("singleChannels");
        }

        if (this.multiChannels != null)
        {
            stream.writeLen(this.multiChannels.size());
            if (!this.multiChannels.isEmpty())
            {
                int   multiChannelsKFreeValue = this.multiChannels.getFreeValue();
                int[] multiChannelsKKeys      = this.multiChannels.getKeys();
                LongObjectMap <ChatChannelData>[] multiChannelsVValues = this.multiChannels.getValues();
                for (int multiChannelsKI = multiChannelsKKeys.Length - 1; multiChannelsKI >= 0; --multiChannelsKI)
                {
                    int multiChannelsK = multiChannelsKKeys[multiChannelsKI];
                    if (multiChannelsK != multiChannelsKFreeValue)
                    {
                        LongObjectMap <ChatChannelData> multiChannelsV = multiChannelsVValues[multiChannelsKI];
                        stream.writeInt(multiChannelsK);

                        if (multiChannelsV != null)
                        {
                            stream.writeLen(multiChannelsV.size());
                            if (!multiChannelsV.isEmpty())
                            {
                                long              multiChannelsVKFreeValue = multiChannelsV.getFreeValue();
                                long[]            multiChannelsVKKeys      = multiChannelsV.getKeys();
                                ChatChannelData[] multiChannelsVVValues    = multiChannelsV.getValues();
                                for (int multiChannelsVKI = multiChannelsVKKeys.Length - 1; multiChannelsVKI >= 0; --multiChannelsVKI)
                                {
                                    long multiChannelsVK = multiChannelsVKKeys[multiChannelsVKI];
                                    if (multiChannelsVK != multiChannelsVKFreeValue)
                                    {
                                        ChatChannelData multiChannelsVV = multiChannelsVVValues[multiChannelsVKI];
                                        stream.writeLong(multiChannelsVK);

                                        if (multiChannelsVV != null)
                                        {
                                            stream.writeDataFullNotNull(multiChannelsVV);
                                        }
                                        else
                                        {
                                            nullObjError("multiChannelsVV");
                                        }
                                    }
                                }
                            }
                        }
                        else
                        {
                            nullObjError("multiChannelsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("multiChannels");
        }

        stream.writeInt(this.chatSendIndex);

        stream.endWriteObj();
    }
Exemplo n.º 3
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        stream.startWriteObj();

        stream.writeInt(this.instanceID);

        if (this.identity != null)
        {
            stream.writeDataFullNotNull(this.identity);
        }
        else
        {
            nullObjError("identity");
        }

        if (this.normal != null)
        {
            stream.writeDataFullNotNull(this.normal);
        }
        else
        {
            nullObjError("normal");
        }

        if (this.pos != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.pos);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.avatar != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.avatar);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.move != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.move);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.fight != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.fight);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.fightEx != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.fightEx);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.ai != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.ai);
        }
        else
        {
            stream.writeBoolean(false);
        }

        if (this.func != null)
        {
            stream.writeBoolean(true);
            stream.writeDataFullNotNull(this.func);
        }
        else
        {
            stream.writeBoolean(false);
        }

        stream.endWriteObj();
    }
Exemplo n.º 4
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        stream.startWriteObj();

        if (this.system != null)
        {
            stream.writeDataFullNotNull(this.system);
        }
        else
        {
            nullObjError("system");
        }

        if (this.gfunc != null)
        {
            stream.writeDataFullNotNull(this.gfunc);
        }
        else
        {
            nullObjError("gfunc");
        }

        if (this.activity != null)
        {
            stream.writeDataFullNotNull(this.activity);
        }
        else
        {
            nullObjError("activity");
        }

        if (this.grole != null)
        {
            stream.writeDataFullNotNull(this.grole);
        }
        else
        {
            nullObjError("grole");
        }

        if (this.gscene != null)
        {
            stream.writeDataFullNotNull(this.gscene);
        }
        else
        {
            nullObjError("gscene");
        }

        if (this.gcharacter != null)
        {
            stream.writeDataFullNotNull(this.gcharacter);
        }
        else
        {
            nullObjError("gcharacter");
        }

        if (this.social != null)
        {
            stream.writeDataFullNotNull(this.social);
        }
        else
        {
            nullObjError("social");
        }

        if (this.gbag != null)
        {
            stream.writeDataFullNotNull(this.gbag);
        }
        else
        {
            nullObjError("gbag");
        }

        if (this.mail != null)
        {
            stream.writeDataFullNotNull(this.mail);
        }
        else
        {
            nullObjError("mail");
        }

        if (this.quest != null)
        {
            stream.writeDataFullNotNull(this.quest);
        }
        else
        {
            nullObjError("quest");
        }

        if (this.guide != null)
        {
            stream.writeDataFullNotNull(this.guide);
        }
        else
        {
            nullObjError("guide");
        }

        if (this.gfriend != null)
        {
            stream.writeDataFullNotNull(this.gfriend);
        }
        else
        {
            nullObjError("gfriend");
        }

        if (this.gunion != null)
        {
            stream.writeDataFullNotNull(this.gunion);
        }
        else
        {
            nullObjError("gunion");
        }

        if (this.gteam != null)
        {
            stream.writeDataFullNotNull(this.gteam);
        }
        else
        {
            nullObjError("gteam");
        }

        stream.endWriteObj();
    }
Exemplo n.º 5
0
    /// <summary>
    /// 写入字节流(完整版)
    /// </summary>
    protected override void toWriteBytesFull(BytesWriteStream stream)
    {
        base.toWriteBytesFull(stream);

        stream.startWriteObj();

        if (this.sellItems != null)
        {
            stream.writeLen(this.sellItems.size());
            if (!this.sellItems.isEmpty())
            {
                AuctionItemData[] sellItemsVValues = this.sellItems.getValues();
                for (int sellItemsVI = sellItemsVValues.Length - 1; sellItemsVI >= 0; --sellItemsVI)
                {
                    AuctionItemData sellItemsV = sellItemsVValues[sellItemsVI];
                    if (sellItemsV != null)
                    {
                        if (sellItemsV != null)
                        {
                            stream.writeDataFullNotNull(sellItemsV);
                        }
                        else
                        {
                            nullObjError("sellItemsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("sellItems");
        }

        if (this.preSellItems != null)
        {
            stream.writeLen(this.preSellItems.size());
            if (!this.preSellItems.isEmpty())
            {
                AuctionItemData[] preSellItemsVValues = this.preSellItems.getValues();
                for (int preSellItemsVI = preSellItemsVValues.Length - 1; preSellItemsVI >= 0; --preSellItemsVI)
                {
                    AuctionItemData preSellItemsV = preSellItemsVValues[preSellItemsVI];
                    if (preSellItemsV != null)
                    {
                        if (preSellItemsV != null)
                        {
                            stream.writeDataFullNotNull(preSellItemsV);
                        }
                        else
                        {
                            nullObjError("preSellItemsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("preSellItems");
        }

        if (this.preBuyItems != null)
        {
            stream.writeLen(this.preBuyItems.size());
            if (!this.preBuyItems.isEmpty())
            {
                AuctionBuyItemData[] preBuyItemsVValues = this.preBuyItems.getValues();
                for (int preBuyItemsVI = preBuyItemsVValues.Length - 1; preBuyItemsVI >= 0; --preBuyItemsVI)
                {
                    AuctionBuyItemData preBuyItemsV = preBuyItemsVValues[preBuyItemsVI];
                    if (preBuyItemsV != null)
                    {
                        if (preBuyItemsV != null)
                        {
                            stream.writeDataFullNotNull(preBuyItemsV);
                        }
                        else
                        {
                            nullObjError("preBuyItemsV");
                        }
                    }
                }
            }
        }
        else
        {
            nullObjError("preBuyItems");
        }

        stream.endWriteObj();
    }