当前位置: 首页>>代码示例>>C#>>正文


C# BigEndianReader.ReadByte方法代码示例

本文整理汇总了C#中BlueSheep.Common.IO.BigEndianReader.ReadByte方法的典型用法代码示例。如果您正苦于以下问题:C# BigEndianReader.ReadByte方法的具体用法?C# BigEndianReader.ReadByte怎么用?C# BigEndianReader.ReadByte使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BlueSheep.Common.IO.BigEndianReader的用法示例。


在下文中一共展示了BigEndianReader.ReadByte方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     byte flag1 = reader.ReadByte();
     enabled = BooleanByteWrapper.GetFlag(flag1, 0);
     abandonnedPaddock = BooleanByteWrapper.GetFlag(flag1, 1);
     level = reader.ReadByte();
     if (level < 0 || level > 255)
         throw new Exception("Forbidden value on level = " + level + ", it doesn't respect the following condition : level < 0 || level > 255");
     expLevelFloor = reader.ReadVarUhLong();
     if (expLevelFloor < 0 || expLevelFloor > 9.007199254740992E15)
         throw new Exception("Forbidden value on expLevelFloor = " + expLevelFloor + ", it doesn't respect the following condition : expLevelFloor < 0 || expLevelFloor > 9.007199254740992E15");
     experience = reader.ReadVarUhLong();
     if (experience < 0 || experience > 9.007199254740992E15)
         throw new Exception("Forbidden value on experience = " + experience + ", it doesn't respect the following condition : experience < 0 || experience > 9.007199254740992E15");
     expNextLevelFloor = reader.ReadVarUhLong();
     if (expNextLevelFloor < 0 || expNextLevelFloor > 9.007199254740992E15)
         throw new Exception("Forbidden value on expNextLevelFloor = " + expNextLevelFloor + ", it doesn't respect the following condition : expNextLevelFloor < 0 || expNextLevelFloor > 9.007199254740992E15");
     creationDate = reader.ReadInt();
     if (creationDate < 0)
         throw new Exception("Forbidden value on creationDate = " + creationDate + ", it doesn't respect the following condition : creationDate < 0");
     nbTotalMembers = reader.ReadVarShort();
     if (nbTotalMembers < 0)
         throw new Exception("Forbidden value on nbTotalMembers = " + nbTotalMembers + ", it doesn't respect the following condition : nbTotalMembers < 0");
     nbConnectedMembers = reader.ReadVarShort();
     if (nbConnectedMembers < 0)
         throw new Exception("Forbidden value on nbConnectedMembers = " + nbConnectedMembers + ", it doesn't respect the following condition : nbConnectedMembers < 0");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:27,代码来源:GuildInformationsGeneralMessage.cs

示例2: Deserialize

 public virtual void Deserialize(BigEndianReader reader)
 {
     var _loc_2 = reader.ReadByte();
     this.cantBeAggressed = BooleanByteWrapper.GetFlag(_loc_2, 0);
     this.cantBeChallenged = BooleanByteWrapper.GetFlag(_loc_2, 1);
     this.cantTrade = BooleanByteWrapper.GetFlag(_loc_2, 2);
     this.cantBeAttackedByMutant = BooleanByteWrapper.GetFlag(_loc_2, 3);
     this.cantRun = BooleanByteWrapper.GetFlag(_loc_2, 4);
     this.forceSlowWalk = BooleanByteWrapper.GetFlag(_loc_2, 5);
     this.cantMinimize = BooleanByteWrapper.GetFlag(_loc_2, 6);
     this.cantMove = BooleanByteWrapper.GetFlag(_loc_2, 7);
     var _loc_3 = reader.ReadByte();
     this.cantAggress = BooleanByteWrapper.GetFlag(_loc_3, 0);
     this.cantChallenge = BooleanByteWrapper.GetFlag(_loc_3, 1);
     this.cantExchange = BooleanByteWrapper.GetFlag(_loc_3, 2);
     this.cantAttack = BooleanByteWrapper.GetFlag(_loc_3, 3);
     this.cantChat = BooleanByteWrapper.GetFlag(_loc_3, 4);
     this.cantBeMerchant = BooleanByteWrapper.GetFlag(_loc_3, 5);
     this.cantUseObject = BooleanByteWrapper.GetFlag(_loc_3, 6);
     this.cantUseTaxCollector = BooleanByteWrapper.GetFlag(_loc_3, 7);
     var _loc_4 = reader.ReadByte();
     this.cantUseInteractive = BooleanByteWrapper.GetFlag(_loc_4, 0);
     this.cantSpeakToNPC = BooleanByteWrapper.GetFlag(_loc_4, 1);
     this.cantChangeZone = BooleanByteWrapper.GetFlag(_loc_4, 2);
     this.cantAttackMonster = BooleanByteWrapper.GetFlag(_loc_4, 3);
     this.cantWalk8Directions = BooleanByteWrapper.GetFlag(_loc_4, 4);
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:27,代码来源:ActorRestrictionsInformations.cs

示例3: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     base.Deserialize(reader);
     guildLevel = reader.ReadByte();
     if (guildLevel < 1 || guildLevel > 200)
         throw new Exception("Forbidden value on guildLevel = " + guildLevel + ", it doesn't respect the following condition : guildLevel < 1 || guildLevel > 200");
     nbMembers = reader.ReadByte();
     if (nbMembers < 1 || nbMembers > 240)
         throw new Exception("Forbidden value on nbMembers = " + nbMembers + ", it doesn't respect the following condition : nbMembers < 1 || nbMembers > 240");
     enabled = reader.ReadBoolean();
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:11,代码来源:GuildInAllianceInformations.cs

示例4: Deserialize

 public virtual void Deserialize(BigEndianReader reader)
 {
     guildId = reader.ReadVarInt();
     if (guildId < 0)
         throw new Exception("Forbidden value on guildId = " + guildId + ", it doesn't respect the following condition : guildId < 0");
     leaderId = reader.ReadVarInt();
     if (leaderId < 0)
         throw new Exception("Forbidden value on leaderId = " + leaderId + ", it doesn't respect the following condition : leaderId < 0");
     guildLevel = reader.ReadByte();
     if (guildLevel < 1 || guildLevel > 200)
         throw new Exception("Forbidden value on guildLevel = " + guildLevel + ", it doesn't respect the following condition : guildLevel < 1 || guildLevel > 200");
     nbMembers = reader.ReadByte();
     if (nbMembers < 1 || nbMembers > 240)
         throw new Exception("Forbidden value on nbMembers = " + nbMembers + ", it doesn't respect the following condition : nbMembers < 1 || nbMembers > 240");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:15,代码来源:GuildVersatileInformations.cs

示例5: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     symbioteUID = reader.ReadVarInt();
     if (symbioteUID < 0)
         throw new Exception("Forbidden value on symbioteUID = " + symbioteUID + ", it doesn't respect the following condition : symbioteUID < 0");
     symbiotePos = reader.ReadByte();
     if (symbiotePos < 0 || symbiotePos > 255)
         throw new Exception("Forbidden value on symbiotePos = " + symbiotePos + ", it doesn't respect the following condition : symbiotePos < 0 || symbiotePos > 255");
     hostUID = reader.ReadVarInt();
     if (hostUID < 0)
         throw new Exception("Forbidden value on hostUID = " + hostUID + ", it doesn't respect the following condition : hostUID < 0");
     hostPos = reader.ReadByte();
     if (hostPos < 0 || hostPos > 255)
         throw new Exception("Forbidden value on hostPos = " + hostPos + ", it doesn't respect the following condition : hostPos < 0 || hostPos > 255");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:15,代码来源:SymbioticObjectAssociateRequestMessage.cs

示例6: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     byte flag1 = reader.ReadByte();
     success = BooleanByteWrapper.GetFlag(flag1, 0);
     session = BooleanByteWrapper.GetFlag(flag1, 1);
     name = reader.ReadUTF();
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:7,代码来源:IgnoredDeleteResultMessage.cs

示例7: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     base.Deserialize(reader);
      byte b= reader.ReadByte();
      this.showExperience = BooleanByteWrapper.GetFlag(b,0);
      this.showExperienceLevelFloor = BooleanByteWrapper.GetFlag(b, 1);
      this.showExperienceNextLevelFloor = BooleanByteWrapper.GetFlag(b, 2);
      this.showExperienceFightDelta = BooleanByteWrapper.GetFlag(b, 3);
      this.showExperienceForGuild = BooleanByteWrapper.GetFlag(b, 4);
      this.showExperienceForMount = BooleanByteWrapper.GetFlag(b, 5);
      this.isIncarnationExperience = BooleanByteWrapper.GetFlag(b, 6);
     experience = reader.ReadVarUhLong();
     if (experience < 0 || experience > 9.007199254740992E15)
         throw new Exception("Forbidden value on experience = " + experience + ", it doesn't respect the following condition : experience < 0 || experience > 9.007199254740992E15");
     experienceLevelFloor = reader.ReadVarUhLong();
     if (experienceLevelFloor < 0 || experienceLevelFloor > 9.007199254740992E15)
         throw new Exception("Forbidden value on experienceLevelFloor = " + experienceLevelFloor + ", it doesn't respect the following condition : experienceLevelFloor < 0 || experienceLevelFloor > 9.007199254740992E15");
     experienceNextLevelFloor = reader.ReadDouble();
     if (experienceNextLevelFloor < 0 || experienceNextLevelFloor > 9.007199254740992E15)
         throw new Exception("Forbidden value on experienceNextLevelFloor = " + experienceNextLevelFloor + ", it doesn't respect the following condition : experienceNextLevelFloor < 0 || experienceNextLevelFloor > 9.007199254740992E15");
     experienceFightDelta = reader.ReadVarInt();
     experienceForGuild = reader.ReadVarInt();
     if (experienceForGuild < 0)
         throw new Exception("Forbidden value on experienceForGuild = " + experienceForGuild + ", it doesn't respect the following condition : experienceForGuild < 0");
     experienceForMount = reader.ReadVarInt();
     if (experienceForMount < 0)
         throw new Exception("Forbidden value on experienceForMount = " + experienceForMount + ", it doesn't respect the following condition : experienceForMount < 0");
     rerollExperienceMul = reader.ReadSByte();
     if (rerollExperienceMul < 0)
         throw new Exception("Forbidden value on rerollExperienceMul = " + rerollExperienceMul + ", it doesn't respect the following condition : rerollExperienceMul < 0");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:31,代码来源:FightResultExperienceData.cs

示例8: Deserialize

 public virtual void Deserialize(BigEndianReader reader)
 {
     var limit = reader.ReadUShort();
     quantities = new int[limit];
     for (int i = 0; i < limit; i++)
     {
          quantities[i] = reader.ReadVarInt();
     }
     limit = reader.ReadUShort();
     types = new int[limit];
     for (int i = 0; i < limit; i++)
     {
          types[i] = reader.ReadVarInt();
     }
     taxPercentage = reader.ReadFloat();
     taxModificationPercentage = reader.ReadFloat();
     maxItemLevel = reader.ReadByte();
     if (maxItemLevel < 0 || maxItemLevel > 255)
         throw new Exception("Forbidden value on maxItemLevel = " + maxItemLevel + ", it doesn't respect the following condition : maxItemLevel < 0 || maxItemLevel > 255");
     maxItemPerAccount = reader.ReadVarInt();
     if (maxItemPerAccount < 0)
         throw new Exception("Forbidden value on maxItemPerAccount = " + maxItemPerAccount + ", it doesn't respect the following condition : maxItemPerAccount < 0");
     npcContextualId = reader.ReadInt();
     unsoldDelay = reader.ReadVarShort();
     if (unsoldDelay < 0)
         throw new Exception("Forbidden value on unsoldDelay = " + unsoldDelay + ", it doesn't respect the following condition : unsoldDelay < 0");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:27,代码来源:SellerBuyerDescriptor.cs

示例9: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     base.Deserialize(reader);
     time = reader.ReadByte();
     if (time < 0 || time > 255)
         throw new Exception("Forbidden value on time = " + time + ", it doesn't respect the following condition : time < 0 || time > 255");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:7,代码来源:SkillActionDescriptionTimed.cs

示例10: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     base.Deserialize(reader);
     emoteId = reader.ReadByte();
     if (emoteId < 0 || emoteId > 255)
         throw new Exception("Forbidden value on emoteId = " + emoteId + ", it doesn't respect the following condition : emoteId < 0 || emoteId > 255");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:7,代码来源:ShortcutEmote.cs

示例11: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     byte flag1 = reader.ReadByte();
     self = BooleanByteWrapper.GetFlag(flag1, 0);
     verbose = BooleanByteWrapper.GetFlag(flag1, 1);
     position = reader.ReadSByte();
     accountNickname = reader.ReadUTF();
     accountId = reader.ReadInt();
     if (accountId < 0)
         throw new Exception("Forbidden value on accountId = " + accountId + ", it doesn't respect the following condition : accountId < 0");
     playerName = reader.ReadUTF();
     playerId = reader.ReadVarInt();
     if (playerId < 0)
         throw new Exception("Forbidden value on playerId = " + playerId + ", it doesn't respect the following condition : playerId < 0");
     areaId = reader.ReadShort();
     var limit = reader.ReadUShort();
     socialGroups = new Types.AbstractSocialGroupInfos[limit];
     for (int i = 0; i < limit; i++)
     {
          socialGroups[i] = Types.ProtocolTypeManager.GetInstance<Types.AbstractSocialGroupInfos>(reader.ReadShort());
          socialGroups[i].Deserialize(reader);
     }
     playerState = reader.ReadSByte();
     if (playerState < 0)
         throw new Exception("Forbidden value on playerState = " + playerState + ", it doesn't respect the following condition : playerState < 0");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:26,代码来源:BasicWhoIsMessage.cs

示例12: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     byte flag1 = reader.ReadByte();
     autoconnect = BooleanByteWrapper.GetFlag(flag1, 0);
     useCertificate = BooleanByteWrapper.GetFlag(flag1, 1);
     useLoginToken = BooleanByteWrapper.GetFlag(flag1, 2);
     version = new Types.VersionExtended();
     version.Deserialize(reader);
     lang = reader.ReadUTF();
     var limit = reader.ReadVarInt();
     credentials = new sbyte[limit];
     for (int i = 0; i < limit; i++)
     {
          credentials[i] = reader.ReadSByte();
     }
     serverId = reader.ReadShort();
     sessionOptionalSalt = reader.ReadDouble();
     if (sessionOptionalSalt < -9.007199254740992E15 || sessionOptionalSalt > 9.007199254740992E15)
         throw new Exception("Forbidden value on sessionOptionalSalt = " + sessionOptionalSalt + ", it doesn't respect the following condition : sessionOptionalSalt < -9.007199254740992E15 || sessionOptionalSalt > 9.007199254740992E15");
     ushort length = reader.ReadUShort();
     failedAttempts = new List<short>();
     for (int i = 0; i < length; i++)
     {
         failedAttempts.Add(reader.ReadVarShort());
     }
 }
开发者ID:Sadikk,项目名称:BlueSheep,代码行数:26,代码来源:IdentificationMessage.cs

示例13: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     lockDuration = reader.ReadByte();
     if (lockDuration < 0 || lockDuration > 255)
         throw new Exception("Forbidden value on lockDuration = " + lockDuration + ", it doesn't respect the following condition : lockDuration < 0 || lockDuration > 255");
     author = reader.ReadUTF();
     content = reader.ReadUTF();
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:8,代码来源:PopupWarningMessage.cs

示例14: Deserialize

 public virtual void Deserialize(BigEndianReader reader)
 {
     byte _loc2_ = reader.ReadByte();
      this.isSecret = BooleanByteWrapper.GetFlag(_loc2_,0);
      this.isRestrictedToPartyOnly = BooleanByteWrapper.GetFlag(_loc2_,1);
      this.isClosed = BooleanByteWrapper.GetFlag(_loc2_,2);
      this.isAskingForHelp = BooleanByteWrapper.GetFlag(_loc2_,3);
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:8,代码来源:FightOptionsInformations.cs

示例15: Deserialize

 public override void Deserialize(BigEndianReader reader)
 {
     base.Deserialize(reader);
     ownerName = reader.ReadUTF();
     level = reader.ReadByte();
     if (level < 0 || level > 255)
         throw new Exception("Forbidden value on level = " + level + ", it doesn't respect the following condition : level < 0 || level > 255");
 }
开发者ID:DjTrilogic,项目名称:BlueSheep,代码行数:8,代码来源:GameRolePlayMountInformations.cs


注:本文中的BlueSheep.Common.IO.BigEndianReader.ReadByte方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。