本文整理汇总了C#中BlueSheep.Common.IO.BigEndianReader.ReadUShort方法的典型用法代码示例。如果您正苦于以下问题:C# BigEndianReader.ReadUShort方法的具体用法?C# BigEndianReader.ReadUShort怎么用?C# BigEndianReader.ReadUShort使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BlueSheep.Common.IO.BigEndianReader
的用法示例。
在下文中一共展示了BigEndianReader.ReadUShort方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Deserialize
public virtual void Deserialize(BigEndianReader reader)
{
fightId = reader.ReadInt();
fightType = reader.ReadSByte();
if (fightType < 0)
throw new Exception("Forbidden value on fightType = " + fightType + ", it doesn't respect the following condition : fightType < 0");
fightStart = reader.ReadInt();
if (fightStart < 0)
throw new Exception("Forbidden value on fightStart = " + fightStart + ", it doesn't respect the following condition : fightStart < 0");
fightSpectatorLocked = reader.ReadBoolean();
var limit = reader.ReadUShort();
fightTeams = new Types.FightTeamLightInformations[limit];
for (int i = 0; i < limit; i++)
{
fightTeams[i] = new Types.FightTeamLightInformations();
fightTeams[i].Deserialize(reader);
}
limit = reader.ReadUShort();
fightTeamsOptions = new Types.FightOptionsInformations[limit];
for (int i = 0; i < limit; i++)
{
fightTeamsOptions[i] = new Types.FightOptionsInformations();
fightTeamsOptions[i].Deserialize(reader);
}
}
示例2: Deserialize
public override void Deserialize(BigEndianReader reader)
{
base.Deserialize(reader);
var limit = reader.ReadUShort();
charactersToRecolor = new Types.CharacterToRecolorInformation[limit];
for (int i = 0; i < limit; i++)
{
charactersToRecolor[i] = new Types.CharacterToRecolorInformation();
charactersToRecolor[i].Deserialize(reader);
}
limit = reader.ReadUShort();
charactersToRename = new int[limit];
for (int i = 0; i < limit; i++)
{
charactersToRename[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
unusableCharacters = new int[limit];
for (int i = 0; i < limit; i++)
{
unusableCharacters[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
charactersToRelook = new Types.CharacterToRelookInformation[limit];
for (int i = 0; i < limit; i++)
{
charactersToRelook[i] = new Types.CharacterToRelookInformation();
charactersToRelook[i].Deserialize(reader);
}
}
示例3: 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");
}
示例4: Deserialize
public override void Deserialize(BigEndianReader reader)
{
base.Deserialize(reader);
partyType = reader.ReadSByte();
if (partyType < 0)
throw new Exception("Forbidden value on partyType = " + partyType + ", it doesn't respect the following condition : partyType < 0");
partyLeaderId = reader.ReadVarInt();
if (partyLeaderId < 0)
throw new Exception("Forbidden value on partyLeaderId = " + partyLeaderId + ", it doesn't respect the following condition : partyLeaderId < 0");
maxParticipants = reader.ReadSByte();
if (maxParticipants < 0)
throw new Exception("Forbidden value on maxParticipants = " + maxParticipants + ", it doesn't respect the following condition : maxParticipants < 0");
var limit = reader.ReadUShort();
members = new Types.PartyMemberInformations[limit];
for (int i = 0; i < limit; i++)
{
members[i] = Types.ProtocolTypeManager.GetInstance<Types.PartyMemberInformations>(reader.ReadShort());
members[i].Deserialize(reader);
}
limit = reader.ReadUShort();
guests = new Types.PartyGuestInformations[limit];
for (int i = 0; i < limit; i++)
{
guests[i] = new Types.PartyGuestInformations();
guests[i].Deserialize(reader);
}
restricted = reader.ReadBoolean();
partyName = reader.ReadUTF();
}
示例5: Deserialize
public virtual void Deserialize(BigEndianReader reader)
{
bonesId = reader.ReadVarShort();
if (bonesId < 0)
throw new Exception("Forbidden value on bonesId = " + bonesId + ", it doesn't respect the following condition : bonesId < 0");
var limit = reader.ReadUShort();
skins = new short[limit];
for (int i = 0; i < limit; i++)
{
skins[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
indexedColors = new int[limit];
for (int i = 0; i < limit; i++)
{
indexedColors[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
scales = new short[limit];
for (int i = 0; i < limit; i++)
{
scales[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
subentities = new Types.SubEntity[limit];
for (int i = 0; i < limit; i++)
{
subentities[i] = new Types.SubEntity();
subentities[i].Deserialize(reader);
}
}
示例6: Deserialize
public override void Deserialize(BigEndianReader reader)
{
base.Deserialize(reader);
partyType = reader.ReadSByte();
if (partyType < 0)
throw new Exception("Forbidden value on partyType = " + partyType + ", it doesn't respect the following condition : partyType < 0");
partyName = reader.ReadUTF();
fromId = reader.ReadVarInt();
if (fromId < 0)
throw new Exception("Forbidden value on fromId = " + fromId + ", it doesn't respect the following condition : fromId < 0");
fromName = reader.ReadUTF();
leaderId = reader.ReadVarInt();
if (leaderId < 0)
throw new Exception("Forbidden value on leaderId = " + leaderId + ", it doesn't respect the following condition : leaderId < 0");
var limit = reader.ReadUShort();
members = new Types.PartyInvitationMemberInformations[limit];
for (int i = 0; i < limit; i++)
{
members[i] = new Types.PartyInvitationMemberInformations();
members[i].Deserialize(reader);
}
limit = reader.ReadUShort();
guests = new Types.PartyGuestInformations[limit];
for (int i = 0; i < limit; i++)
{
guests[i] = new Types.PartyGuestInformations();
guests[i].Deserialize(reader);
}
}
示例7: Deserialize
public virtual void Deserialize(BigEndianReader reader)
{
fightId = reader.ReadInt();
fightType = reader.ReadSByte();
if (fightType < 0)
throw new Exception("Forbidden value on fightType = " + fightType + ", it doesn't respect the following condition : fightType < 0");
var limit = reader.ReadUShort();
fightTeams = new Types.FightTeamInformations[limit];
for (int i = 0; i < limit; i++)
{
fightTeams[i] = Types.ProtocolTypeManager.GetInstance<Types.FightTeamInformations>(reader.ReadShort());
fightTeams[i].Deserialize(reader);
}
limit = reader.ReadUShort();
fightTeamsPositions = new short[limit];
for (int i = 0; i < limit; i++)
{
fightTeamsPositions[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
fightTeamsOptions = new Types.FightOptionsInformations[limit];
for (int i = 0; i < limit; i++)
{
fightTeamsOptions[i] = new Types.FightOptionsInformations();
fightTeamsOptions[i].Deserialize(reader);
}
}
示例8: Deserialize
public override void Deserialize(BigEndianReader reader)
{
teleporterType = reader.ReadSByte();
if (teleporterType < 0)
throw new Exception("Forbidden value on teleporterType = " + teleporterType + ", it doesn't respect the following condition : teleporterType < 0");
var limit = reader.ReadUShort();
mapIds = new int[limit];
for (int i = 0; i < limit; i++)
{
mapIds[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
subAreaIds = new short[limit];
for (int i = 0; i < limit; i++)
{
subAreaIds[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
costs = new short[limit];
for (int i = 0; i < limit; i++)
{
costs[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
destTeleporterType = new sbyte[limit];
for (int i = 0; i < limit; i++)
{
destTeleporterType[i] = reader.ReadSByte();
}
}
示例9: Deserialize
public override void Deserialize(BigEndianReader reader)
{
position = reader.ReadUShort();
if (position < 0 || position > 65535)
throw new Exception("Forbidden value on position = " + position + ", it doesn't respect the following condition : position < 0 || position > 65535");
total = reader.ReadUShort();
if (total < 0 || total > 65535)
throw new Exception("Forbidden value on total = " + total + ", it doesn't respect the following condition : total < 0 || total > 65535");
}
示例10: Deserialize
public override void Deserialize(BigEndianReader reader)
{
subAreaId = reader.ReadVarShort();
if (subAreaId < 0)
throw new Exception("Forbidden value on subAreaId = " + subAreaId + ", it doesn't respect the following condition : subAreaId < 0");
mapId = reader.ReadInt();
if (mapId < 0)
throw new Exception("Forbidden value on mapId = " + mapId + ", it doesn't respect the following condition : mapId < 0");
var limit = reader.ReadUShort();
houses = new Types.HouseInformations[limit];
for (int i = 0; i < limit; i++)
{
houses[i] = Types.ProtocolTypeManager.GetInstance<Types.HouseInformations>(reader.ReadShort());
houses[i].Deserialize(reader);
}
limit = reader.ReadUShort();
actors = new Types.GameRolePlayActorInformations[limit];
for (int i = 0; i < limit; i++)
{
short id = reader.ReadShort();
actors[i] = Types.ProtocolTypeManager.GetInstance<Types.GameRolePlayActorInformations>(id);
actors[i].Deserialize(reader);
}
limit = reader.ReadUShort();
interactiveElements = new Types.InteractiveElement[limit];
for (int i = 0; i < limit; i++)
{
interactiveElements[i] = Types.ProtocolTypeManager.GetInstance<Types.InteractiveElement>(reader.ReadShort());
interactiveElements[i].Deserialize(reader);
}
limit = reader.ReadUShort();
statedElements = new Types.StatedElement[limit];
for (int i = 0; i < limit; i++)
{
statedElements[i] = new Types.StatedElement();
statedElements[i].Deserialize(reader);
}
limit = reader.ReadUShort();
obstacles = new Types.MapObstacle[limit];
for (int i = 0; i < limit; i++)
{
obstacles[i] = new Types.MapObstacle();
obstacles[i].Deserialize(reader);
}
limit = reader.ReadUShort();
fights = new Types.FightCommonInformations[limit];
for (int i = 0; i < limit; i++)
{
fights[i] = new Types.FightCommonInformations();
fights[i].Deserialize(reader);
}
}
示例11: Deserialize
public override void Deserialize(BigEndianReader reader)
{
accountId = reader.ReadInt();
if (accountId < 0)
throw new Exception("Forbidden value on accountId = " + accountId + ", it doesn't respect the following condition : accountId < 0");
tutorialAvailable = reader.ReadBoolean();
breedsVisible = reader.ReadUShort();
if (breedsVisible < 0 || breedsVisible > 65535)
throw new Exception("Forbidden value on breedsVisible = " + breedsVisible + ", it doesn't respect the following condition : breedsVisible < 0 || breedsVisible > 65535");
breedsAvailable = reader.ReadUShort();
if (breedsAvailable < 0 || breedsAvailable > 65535)
throw new Exception("Forbidden value on breedsAvailable = " + breedsAvailable + ", it doesn't respect the following condition : breedsAvailable < 0 || breedsAvailable > 65535");
status = reader.ReadSByte();
}
示例12: Deserialize
public override void Deserialize(BigEndianReader reader)
{
var limit = reader.ReadUShort();
targetIds = new int[limit];
for (int i = 0; i < limit; i++)
{
targetIds[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
targetCells = new short[limit];
for (int i = 0; i < limit; i++)
{
targetCells[i] = reader.ReadShort();
}
}
示例13: Deserialize
public override void Deserialize(BigEndianReader reader)
{
var limit = reader.ReadUShort();
channels = new sbyte[limit];
for (int i = 0; i < limit; i++)
{
channels[i] = reader.ReadSByte();
}
limit = reader.ReadUShort();
disallowed = new sbyte[limit];
for (int i = 0; i < limit; i++)
{
disallowed[i] = reader.ReadSByte();
}
}
示例14: Deserialize
public override void Deserialize(BigEndianReader reader)
{
var limit = reader.ReadUShort();
ids = new int[limit];
for (int i = 0; i < limit; i++)
{
ids[i] = reader.ReadInt();
}
limit = reader.ReadUShort();
deadsIds = new int[limit];
for (int i = 0; i < limit; i++)
{
deadsIds[i] = reader.ReadInt();
}
}
示例15: Deserialize
public override void Deserialize(BigEndianReader reader)
{
var limit = reader.ReadUShort();
ids = new short[limit];
for (int i = 0; i < limit; i++)
{
ids[i] = reader.ReadVarShort();
}
limit = reader.ReadUShort();
avgPrices = new int[limit];
for (int i = 0; i < limit; i++)
{
avgPrices[i] = reader.ReadVarInt();
}
}