public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeInt32(this.iEventID); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeInt32(this.iEventParam1); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iEventParam2); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iEventParam3); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iEventParam4); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || SCPKG_CMD_CHG_INTIMACY_CONFIRM.CURRVERSION < cutVer) { cutVer = SCPKG_CMD_CHG_INTIMACY_CONFIRM.CURRVERSION; } if (SCPKG_CMD_CHG_INTIMACY_CONFIRM.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = this.stUin.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bIntimacyState); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bRelationChgType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwTerminateTime); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwResult); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt8(this.bMapType); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt32(this.dwMapId); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bGameMode); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bIsWarmBattle); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bAILevel); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_APOLLO_TRANK_USERBUFFER.CURRVERSION < cutVer) { cutVer = COMDT_APOLLO_TRANK_USERBUFFER.CURRVERSION; } if (COMDT_APOLLO_TRANK_USERBUFFER.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt64(this.ullUid); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bOptType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iScoreType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bImage); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stExtraInfo.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || SCPKG_GET_GUILD_MEMBER_GAME_STATE_RSP.CURRVERSION < cutVer) { cutVer = SCPKG_GET_GUILD_MEMBER_GAME_STATE_RSP.CURRVERSION; } if (SCPKG_GET_GUILD_MEMBER_GAME_STATE_RSP.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iMemberCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } if (0 > this.iMemberCnt) { return(TdrError.ErrorType.TDR_ERR_MINUS_REFER_VALUE); } if (150 < this.iMemberCnt) { return(TdrError.ErrorType.TDR_ERR_REFER_SURPASS_COUNT); } if (this.astMemberInfo.Length < this.iMemberCnt) { return(TdrError.ErrorType.TDR_ERR_VAR_ARRAY_CONFLICT); } for (int i = 0; i < this.iMemberCnt; i++) { errorType = this.astMemberInfo[i].pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_TRANSACTION_COMMON.CURRVERSION < cutVer) { cutVer = COMDT_TRANSACTION_COMMON.CURRVERSION; } if (COMDT_TRANSACTION_COMMON.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt32(this.dwTransId); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwTransSeq); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bActionIndex); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bOptType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iScoreType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_APOLLO_PAY_BUYSKIN.CURRVERSION < cutVer) { cutVer = COMDT_APOLLO_PAY_BUYSKIN.CURRVERSION; } if (COMDT_APOLLO_PAY_BUYSKIN.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt32(this.dwSkinID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bUseAkaliShop); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iItemIndex); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwShopID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt16(this.wZheKou); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || LBSCell.CURRVERSION < cutVer) { cutVer = LBSCell.CURRVERSION; } if (LBSCell.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iMcc); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iMnc); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iLac); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iCellId); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iRssi); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_TRANSACTION_MSG_OF_IDIP_DELACNTPKGINFOREQ.CURRVERSION < cutVer) { cutVer = COMDT_TRANSACTION_MSG_OF_IDIP_DELACNTPKGINFOREQ.CURRVERSION; } if (COMDT_TRANSACTION_MSG_OF_IDIP_DELACNTPKGINFOREQ.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt64(this.ullUid); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwLogicWordID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt16(this.wInfoType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwItemID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iItemNum); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt16(this.wYear); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt8(this.bMonth); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bDay); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bHour); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwHeroID); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_APOLLO_PAY_GAMESWEEP.CURRVERSION < cutVer) { cutVer = COMDT_APOLLO_PAY_GAMESWEEP.CURRVERSION; } if (COMDT_APOLLO_PAY_GAMESWEEP.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iLevelID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bGameType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwSweepCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwAPUse); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwTicketUse); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_GUILD_MATCH_MEMBER_SCORE_CHG.CURRVERSION < cutVer) { cutVer = COMDT_GUILD_MATCH_MEMBER_SCORE_CHG.CURRVERSION; } if (COMDT_GUILD_MATCH_MEMBER_SCORE_CHG.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt64(this.ullUid); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwScore); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwWeekScore); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bContinueWin); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bWeekMatchCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_SETTLE_COMMON_DATA.CURRVERSION < cutVer) { cutVer = COMDT_SETTLE_COMMON_DATA.CURRVERSION; } if (COMDT_SETTLE_COMMON_DATA.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = this.stStatisticData.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stHeroData.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stGeneralData.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stNonHeroData.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stOtherData.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_DESKINFO.CURRVERSION < cutVer) { cutVer = COMDT_DESKINFO.CURRVERSION; } if (COMDT_DESKINFO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt8(this.bMapType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwMapId); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bGameMode); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bIsWarmBattle); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bAILevel); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || CSDT_CHEAT_SET_MASTERHERO.CURRVERSION < cutVer) { cutVer = CSDT_CHEAT_SET_MASTERHERO.CURRVERSION; } if (CSDT_CHEAT_SET_MASTERHERO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt64(this.ullAcntID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iWorldLogicId); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwHeroID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwWinCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwGameCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_RANKING_LIST_ITEM_EXTRA_MASTER_HERO.CURRVERSION < cutVer) { cutVer = COMDT_RANKING_LIST_ITEM_EXTRA_MASTER_HERO.CURRVERSION; } if (COMDT_RANKING_LIST_ITEM_EXTRA_MASTER_HERO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt32(this.dwWinCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwGameCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stAcntInfo.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stEquipList.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stSymbolPageInfo.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || CSDT_LBS_USER_INFO.CURRVERSION < cutVer) { cutVer = CSDT_LBS_USER_INFO.CURRVERSION; } if (CSDT_LBS_USER_INFO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = this.stLbsUserInfo.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwDistance); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bGradeOfRank); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bMaxGradeOfRank); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwGameSvrEntity); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_BAN_PICK_LOG_INFO.CURRVERSION < cutVer) { cutVer = COMDT_BAN_PICK_LOG_INFO.CURRVERSION; } if (COMDT_BAN_PICK_LOG_INFO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt8(this.bIsBanOrPick); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwHeroID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwUseTimeMs); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bUserGrade); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bIsTimeout); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeInt32(this.iLevelID); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt8(this.bGameType); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwSweepCnt); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwAPUse); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwTicketUse); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt8(this.bOldGrade); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt32(this.dwOldClass); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bNewGrade); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwNewClass); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = this.stDetail.pack(ref destBuf, cutVer); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt64(this.ullUid); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt32(this.dwLogicWordID); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt16(this.wInfoType); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwItemID); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iItemNum); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt64(this.ullAcntID); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeInt32(this.iWorldLogicId); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwHeroID); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwWinCnt); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwGameCnt); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || SCPKG_HONORINFOCHG_RSP.CURRVERSION < cutVer) { cutVer = SCPKG_HONORINFOCHG_RSP.CURRVERSION; } if (SCPKG_HONORINFOCHG_RSP.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iHonorID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iHonorLevel); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iHonorPoint); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iCurUseHonorID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeInt32(this.iCurUseHonorLevel); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || ShareStatusList.CURRVERSION < cutVer) { cutVer = ShareStatusList.CURRVERSION; } if (ShareStatusList.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iCount); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } if (0 > this.iCount) { return(TdrError.ErrorType.TDR_ERR_MINUS_REFER_VALUE); } if (50 < this.iCount) { return(TdrError.ErrorType.TDR_ERR_REFER_SURPASS_COUNT); } if (this.astShareStatus.Length < this.iCount) { return(TdrError.ErrorType.TDR_ERR_VAR_ARRAY_CONFLICT); } for (int i = 0; i < this.iCount; i++) { errorType = this.astShareStatus[i].pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt32(this.dwTransId); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt32(this.dwTransSeq); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bActionIndex); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bOptType); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iScoreType); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }
public TdrError.ErrorType packTLV(ref byte[] buffer, int size, ref int used, bool useVarInt) { if (buffer == null || buffer.GetLength(0) == 0 || size > buffer.GetLength(0)) { return(TdrError.ErrorType.TDR_ERR_INVALID_BUFFER_PARAMETER); } TdrWriteBuf tdrWriteBuf = new TdrWriteBuf(ref buffer, size); TdrError.ErrorType errorType; if (useVarInt) { errorType = tdrWriteBuf.writeUInt8(170); } else { errorType = tdrWriteBuf.writeUInt8(153); } if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } int usedSize = tdrWriteBuf.getUsedSize(); errorType = tdrWriteBuf.reserve(4); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.packTLV(ref tdrWriteBuf, useVarInt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } used = tdrWriteBuf.getUsedSize(); tdrWriteBuf.writeInt32(used, usedSize); return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_HERO_EQUIP_DETAIL.CURRVERSION < cutVer) { cutVer = COMDT_HERO_EQUIP_DETAIL.CURRVERSION; } if (COMDT_HERO_EQUIP_DETAIL.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt8(this.bSelfDefine); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stEquipName.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stEquipInfo.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwWinNum); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwLoseNum); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || COMDT_NORMAL_MMR_GAME_TYPE_INFO.CURRVERSION < cutVer) { cutVer = COMDT_NORMAL_MMR_GAME_TYPE_INFO.CURRVERSION; } if (COMDT_NORMAL_MMR_GAME_TYPE_INFO.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeInt32(this.iMMR); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwWinNum); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwTotalNum); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwContinuousWin); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwContinuousLose); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { if (cutVer == 0u || SCPKG_WEAL_EXCHANGE_RES.CURRVERSION < cutVer) { cutVer = SCPKG_WEAL_EXCHANGE_RES.CURRVERSION; } if (SCPKG_WEAL_EXCHANGE_RES.BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } TdrError.ErrorType errorType = destBuf.writeUInt8(this.bWealType); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwWealID); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt8(this.bWealIdx); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = destBuf.writeUInt32(this.dwDrawCnt); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } errorType = this.stExchangeRes.pack(ref destBuf, cutVer); if (errorType != TdrError.ErrorType.TDR_NO_ERROR) { return(errorType); } return(errorType); }
public override TdrError.ErrorType pack(ref TdrWriteBuf destBuf, uint cutVer) { TdrError.ErrorType type = TdrError.ErrorType.TDR_NO_ERROR; if ((cutVer == 0) || (CURRVERSION < cutVer)) { cutVer = CURRVERSION; } if (BASEVERSION > cutVer) { return(TdrError.ErrorType.TDR_ERR_CUTVER_TOO_SMALL); } type = destBuf.writeUInt32(this.dwHeroId); if (type == TdrError.ErrorType.TDR_NO_ERROR) { type = destBuf.writeUInt16(this.wHeroLevel); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeInt32(this.iHeroStar); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt32(this.dwHeroProficiency); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } type = destBuf.writeUInt8(this.bHeroProficiencyLv); if (type != TdrError.ErrorType.TDR_NO_ERROR) { return(type); } } return(type); }