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


C# ICustomDataInput.ReadVarUhLong方法代码示例

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


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

示例1: Deserialize

 public override void Deserialize(ICustomDataInput 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.ReadVarUhShort();
     if (nbTotalMembers < 0)
         throw new Exception("Forbidden value on nbTotalMembers = " + nbTotalMembers + ", it doesn't respect the following condition : nbTotalMembers < 0");
     nbConnectedMembers = reader.ReadVarUhShort();
     if (nbConnectedMembers < 0)
         throw new Exception("Forbidden value on nbConnectedMembers = " + nbConnectedMembers + ", it doesn't respect the following condition : nbConnectedMembers < 0");
 }
开发者ID:thomasvinot,项目名称:Symbioz,代码行数:27,代码来源:GuildInformationsGeneralMessage.cs

示例2: Deserialize

 public override void Deserialize(ICustomDataInput reader)
 {
     experienceCharacter = reader.ReadVarUhLong();
     if ((experienceCharacter < 0) || (experienceCharacter > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceCharacter = " + experienceCharacter + ", it doesn't respect the following condition : (experienceCharacter < 0) || (experienceCharacter > 9.007199254740992E15)");
     experienceMount = reader.ReadVarUhLong();
     if ((experienceMount < 0) || (experienceMount > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceMount = " + experienceMount + ", it doesn't respect the following condition : (experienceMount < 0) || (experienceMount > 9.007199254740992E15)");
     experienceGuild = reader.ReadVarUhLong();
     if ((experienceGuild < 0) || (experienceGuild > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceGuild = " + experienceGuild + ", it doesn't respect the following condition : (experienceGuild < 0) || (experienceGuild > 9.007199254740992E15)");
     experienceIncarnation = reader.ReadVarUhLong();
     if ((experienceIncarnation < 0) || (experienceIncarnation > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceIncarnation = " + experienceIncarnation + ", it doesn't respect the following condition : (experienceIncarnation < 0) || (experienceIncarnation > 9.007199254740992E15)");
 }
开发者ID:thomasvinot,项目名称:Symbioz,代码行数:15,代码来源:CharacterExperienceGainMessage.cs

示例3: Deserialize

 public override void Deserialize(ICustomDataInput reader)
 {
     base.Deserialize(reader);
     maxPods = reader.ReadVarUhShort();
     if (maxPods < 0)
         throw new Exception("Forbidden value on maxPods = " + maxPods + ", it doesn't respect the following condition : maxPods < 0");
     prospecting = reader.ReadVarUhShort();
     if (prospecting < 0)
         throw new Exception("Forbidden value on prospecting = " + prospecting + ", it doesn't respect the following condition : prospecting < 0");
     wisdom = reader.ReadVarUhShort();
     if (wisdom < 0)
         throw new Exception("Forbidden value on wisdom = " + wisdom + ", it doesn't respect the following condition : wisdom < 0");
     taxCollectorsCount = reader.ReadSByte();
     if (taxCollectorsCount < 0)
         throw new Exception("Forbidden value on taxCollectorsCount = " + taxCollectorsCount + ", it doesn't respect the following condition : taxCollectorsCount < 0");
     taxCollectorAttack = reader.ReadInt();
     kamas = reader.ReadVarUhInt();
     if (kamas < 0)
         throw new Exception("Forbidden value on kamas = " + kamas + ", it doesn't respect the following condition : kamas < 0");
     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)");
     pods = reader.ReadVarUhInt();
     if (pods < 0)
         throw new Exception("Forbidden value on pods = " + pods + ", it doesn't respect the following condition : pods < 0");
     itemsValue = reader.ReadVarUhInt();
     if (itemsValue < 0)
         throw new Exception("Forbidden value on itemsValue = " + itemsValue + ", it doesn't respect the following condition : itemsValue < 0");
 }
开发者ID:thomasvinot,项目名称:Symbioz,代码行数:29,代码来源:TaxCollectorDialogQuestionExtendedMessage.cs

示例4: Deserialize

 public override void Deserialize(ICustomDataInput reader)
 {
     base.Deserialize(reader);
     byte flag1 = reader.ReadByte();
     showExperience = BooleanByteWrapper.GetFlag(flag1, 0);
     showExperienceLevelFloor = BooleanByteWrapper.GetFlag(flag1, 1);
     showExperienceNextLevelFloor = BooleanByteWrapper.GetFlag(flag1, 2);
     showExperienceFightDelta = BooleanByteWrapper.GetFlag(flag1, 3);
     showExperienceForGuild = BooleanByteWrapper.GetFlag(flag1, 4);
     showExperienceForMount = BooleanByteWrapper.GetFlag(flag1, 5);
     isIncarnationExperience = BooleanByteWrapper.GetFlag(flag1, 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.ReadVarUhInt();
     if (experienceForGuild < 0)
         throw new Exception("Forbidden value on experienceForGuild = " + experienceForGuild + ", it doesn't respect the following condition : experienceForGuild < 0");
     experienceForMount = reader.ReadVarUhInt();
     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:thomasvinot,项目名称:Symbioz,代码行数:31,代码来源:FightResultExperienceData.cs

示例5: Deserialize

 public override void Deserialize(ICustomDataInput reader)
 {
     base.Deserialize(reader);
     kamas = reader.ReadVarUhInt();
     if (kamas < 0)
         throw new Exception("Forbidden value on kamas = " + kamas + ", it doesn't respect the following condition : kamas < 0");
     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)");
     pods = reader.ReadVarUhInt();
     if (pods < 0)
         throw new Exception("Forbidden value on pods = " + pods + ", it doesn't respect the following condition : pods < 0");
     itemsValue = reader.ReadVarUhInt();
     if (itemsValue < 0)
         throw new Exception("Forbidden value on itemsValue = " + itemsValue + ", it doesn't respect the following condition : itemsValue < 0");
 }
开发者ID:thomasvinot,项目名称:Symbioz,代码行数:16,代码来源:TaxCollectorLootInformations.cs

示例6: Deserialize

 public virtual void Deserialize(ICustomDataInput reader)
 {
     byte flag1 = reader.ReadByte();
     sex = BooleanByteWrapper.GetFlag(flag1, 0);
     isRideable = BooleanByteWrapper.GetFlag(flag1, 1);
     isWild = BooleanByteWrapper.GetFlag(flag1, 2);
     isFecondationReady = BooleanByteWrapper.GetFlag(flag1, 3);
     id = reader.ReadDouble();
     if ((id < -9.007199254740992E15) || (id > 9.007199254740992E15))
         throw new Exception("Forbidden value on id = " + id + ", it doesn't respect the following condition : (id < -9.007199254740992E15) || (id > 9.007199254740992E15)");
     model = reader.ReadVarUhInt();
     if (model < 0)
         throw new Exception("Forbidden value on model = " + model + ", it doesn't respect the following condition : model < 0");
     var limit = reader.ReadUShort();
     ancestor = new int[limit];
     for (int i = 0; i < limit; i++)
     {
          (ancestor as int[])[i] = reader.ReadInt();
     }
     limit = reader.ReadUShort();
     behaviors = new int[limit];
     for (int i = 0; i < limit; i++)
     {
          (behaviors as int[])[i] = reader.ReadInt();
     }
     name = reader.ReadUTF();
     ownerId = reader.ReadInt();
     if (ownerId < 0)
         throw new Exception("Forbidden value on ownerId = " + ownerId + ", it doesn't respect the following condition : ownerId < 0");
     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)");
     experienceForLevel = reader.ReadVarUhLong();
     if ((experienceForLevel < 0) || (experienceForLevel > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceForLevel = " + experienceForLevel + ", it doesn't respect the following condition : (experienceForLevel < 0) || (experienceForLevel > 9.007199254740992E15)");
     experienceForNextLevel = reader.ReadDouble();
     if ((experienceForNextLevel < -9.007199254740992E15) || (experienceForNextLevel > 9.007199254740992E15))
         throw new Exception("Forbidden value on experienceForNextLevel = " + experienceForNextLevel + ", it doesn't respect the following condition : (experienceForNextLevel < -9.007199254740992E15) || (experienceForNextLevel > 9.007199254740992E15)");
     level = reader.ReadSByte();
     if (level < 0)
         throw new Exception("Forbidden value on level = " + level + ", it doesn't respect the following condition : level < 0");
     maxPods = reader.ReadVarUhInt();
     if (maxPods < 0)
         throw new Exception("Forbidden value on maxPods = " + maxPods + ", it doesn't respect the following condition : maxPods < 0");
     stamina = reader.ReadVarUhInt();
     if (stamina < 0)
         throw new Exception("Forbidden value on stamina = " + stamina + ", it doesn't respect the following condition : stamina < 0");
     staminaMax = reader.ReadVarUhInt();
     if (staminaMax < 0)
         throw new Exception("Forbidden value on staminaMax = " + staminaMax + ", it doesn't respect the following condition : staminaMax < 0");
     maturity = reader.ReadVarUhInt();
     if (maturity < 0)
         throw new Exception("Forbidden value on maturity = " + maturity + ", it doesn't respect the following condition : maturity < 0");
     maturityForAdult = reader.ReadVarUhInt();
     if (maturityForAdult < 0)
         throw new Exception("Forbidden value on maturityForAdult = " + maturityForAdult + ", it doesn't respect the following condition : maturityForAdult < 0");
     energy = reader.ReadVarUhInt();
     if (energy < 0)
         throw new Exception("Forbidden value on energy = " + energy + ", it doesn't respect the following condition : energy < 0");
     energyMax = reader.ReadVarUhInt();
     if (energyMax < 0)
         throw new Exception("Forbidden value on energyMax = " + energyMax + ", it doesn't respect the following condition : energyMax < 0");
     serenity = reader.ReadInt();
     aggressivityMax = reader.ReadInt();
     serenityMax = reader.ReadVarUhInt();
     if (serenityMax < 0)
         throw new Exception("Forbidden value on serenityMax = " + serenityMax + ", it doesn't respect the following condition : serenityMax < 0");
     love = reader.ReadVarUhInt();
     if (love < 0)
         throw new Exception("Forbidden value on love = " + love + ", it doesn't respect the following condition : love < 0");
     loveMax = reader.ReadVarUhInt();
     if (loveMax < 0)
         throw new Exception("Forbidden value on loveMax = " + loveMax + ", it doesn't respect the following condition : loveMax < 0");
     fecondationTime = reader.ReadInt();
     boostLimiter = reader.ReadInt();
     if (boostLimiter < 0)
         throw new Exception("Forbidden value on boostLimiter = " + boostLimiter + ", it doesn't respect the following condition : boostLimiter < 0");
     boostMax = reader.ReadDouble();
     if ((boostMax < -9.007199254740992E15) || (boostMax > 9.007199254740992E15))
         throw new Exception("Forbidden value on boostMax = " + boostMax + ", it doesn't respect the following condition : (boostMax < -9.007199254740992E15) || (boostMax > 9.007199254740992E15)");
     reproductionCount = reader.ReadInt();
     reproductionCountMax = reader.ReadVarUhInt();
     if (reproductionCountMax < 0)
         throw new Exception("Forbidden value on reproductionCountMax = " + reproductionCountMax + ", it doesn't respect the following condition : reproductionCountMax < 0");
     limit = reader.ReadUShort();
     effectList = new Types.ObjectEffectInteger[limit];
     for (int i = 0; i < limit; i++)
     {
          (effectList as Types.ObjectEffectInteger[])[i] = new Types.ObjectEffectInteger();
          (effectList as Types.ObjectEffectInteger[])[i].Deserialize(reader);
     }
 }
开发者ID:thomasvinot,项目名称:Symbioz,代码行数:92,代码来源:MountClientData.cs


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