Beispiel #1
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Type = stream.ReadSByte();
     X = (double)stream.ReadInt() / 32.0d;
     Y = (double)stream.ReadInt() / 32.0d;
     Z = (double)stream.ReadInt() / 32.0d;
 }
Beispiel #2
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Type = (ObjectType)stream.ReadSByte();
     X = (double)stream.ReadInt() / 32.0d; // ((double)intX / 32.0d) => representation of X as double
     Y = (double)stream.ReadInt() / 32.0d;
     Z = (double)stream.ReadInt() / 32.0d;
     UnknownFlag = stream.ReadInt();
     UnknownA = stream.ReadShort();
     UnknownB = stream.ReadShort();
     UnknownC = stream.ReadShort();
 }
Beispiel #3
0
        public override void Read(BigEndianStream stream)
        {
            int posX = stream.ReadInt();
            short posY = stream.ReadShort();
            int posZ = stream.ReadInt();
            byte sizeX = (byte)(stream.ReadByte() + 1);
            byte sizeY = (byte)(stream.ReadByte() + 1);
            byte sizeZ = (byte)(stream.ReadByte() + 1);

            int o = sizeX * sizeY * sizeZ;
            Chunk = new Chunk(null, posX, posZ);

            int len = stream.ReadInt();
            byte[] comp = new byte[len];
            byte[] data = new byte[o * 5 / 2];
            len = stream.Read(comp, 0, len);
        }
Beispiel #4
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Type = (MobType)stream.ReadByte();
     X = (double)stream.ReadInt() / 32.0d;
     Y = (double)stream.ReadInt() / 32.0d;
     Z = (double)stream.ReadInt() / 32.0d;
     Yaw = stream.ReadSByte();
     Pitch = stream.ReadSByte();
     Data = stream.ReadMetaData();
 }
Beispiel #5
0
 public override void Read(BigEndianStream stream)
 {
     PlayerId = stream.ReadInt();
     InBed = stream.ReadSByte();
     X = stream.ReadInt();
     Y = stream.ReadSByte();
     Z = stream.ReadInt();
 }
Beispiel #6
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Title = stream.ReadString16(13);
     X = stream.ReadInt();
     Y = stream.ReadInt();
     Z = stream.ReadInt();
     GraphicId = stream.ReadInt();
 }
Beispiel #7
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     EntityStatus = stream.ReadSByte();
 }
Beispiel #8
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Effect = (EntityEffects)stream.ReadByte();
     Amplifier = stream.ReadByte();
     Duration = stream.ReadShort();
 }
Beispiel #9
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Yaw = stream.ReadSByte();
     Pitch = stream.ReadSByte();
 }
Beispiel #10
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Z = stream.ReadInt();
     Load = stream.ReadBool();
 }
Beispiel #11
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     PlayerId = stream.ReadInt();
 }
Beispiel #12
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Y = stream.ReadSByte();
     Z = stream.ReadInt();
     Face = (BlockFace)stream.ReadSByte();
     Item = ItemStack.Read(stream);
     //amount in hand and durability are handled int ItemStack.Read
 }
Beispiel #13
0
 public override void Read(BigEndianStream stream)
 {
     Action = (DigAction)stream.ReadByte();
     X = stream.ReadInt();
     Y = stream.ReadSByte();
     Z = stream.ReadInt();
     Face = stream.ReadSByte();
 }
Beispiel #14
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     VehicleId = stream.ReadInt();
 }
Beispiel #15
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     PlayerName = stream.ReadString16(16);
     X = (double)stream.ReadInt() / 32.0d;
     Y = (double)stream.ReadInt() / 32.0d;
     Z = (double)stream.ReadInt() / 32.0d;
     Yaw = stream.ReadSByte();
     Pitch = stream.ReadSByte();
     CurrentItem = stream.ReadShort();
 }
Beispiel #16
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Z = stream.ReadInt();
     short length = stream.ReadShort();
     Coords = new short[length];
     Types = new sbyte[length];
     Metadata = new sbyte[length];
     for (int i = 0; i < Coords.Length; i++)
         Coords[i] = stream.ReadShort();
     for (int i = 0; i < Types.Length; i++)
         Types[i] = stream.ReadSByte();
     for (int i = 0; i < Metadata.Length; i++)
         Metadata[i] = stream.ReadSByte();
 }
Beispiel #17
0
 public override void Read(BigEndianStream stream)
 {
     User = stream.ReadInt();
     Target = stream.ReadInt();
     LeftClick = stream.ReadBool();
 }
Beispiel #18
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Effect = (EntityEffects)stream.ReadByte();
 }
Beispiel #19
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Y = stream.ReadSByte();
     Z = stream.ReadInt();
     Type = stream.ReadByte();
     Data = stream.ReadByte();
 }
Beispiel #20
0
 public override void Read(BigEndianStream stream)
 {
     EffectID = (SoundEffect)stream.ReadInt();
     X = stream.ReadInt();
     Y = stream.ReadByte();
     Z = stream.ReadInt();
     SoundData = stream.ReadInt();
 }
Beispiel #21
0
 public override void Read(BigEndianStream stream)
 {
     PlayerId = stream.ReadInt();
     Action = (ActionType)stream.ReadSByte();
 }
Beispiel #22
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     ItemId = stream.ReadShort();
     Count = stream.ReadSByte();
     Durability = stream.ReadShort();
     X = (double)stream.ReadInt() / 32.0d;
     Y = (double)stream.ReadInt() / 32.0d;
     Z = (double)stream.ReadInt() / 32.0d;
     Yaw = stream.ReadSByte();
     Pitch = stream.ReadSByte();
     Roll = stream.ReadSByte();
 }
Beispiel #23
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Slot = stream.ReadShort();
     ItemId = stream.ReadShort();
     Durability = stream.ReadShort();
 }
Beispiel #24
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Y = stream.ReadInt();
     Z = stream.ReadInt();
 }
Beispiel #25
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Data = stream.ReadMetaData();
 }
Beispiel #26
0
 public override void Read(BigEndianStream stream)
 {
     ProtocolOrEntityId = stream.ReadInt();
     Username = stream.ReadString16(16);
     MapSeed = stream.ReadLong();
     ServerMode = stream.ReadInt();
     Dimension = stream.ReadSByte();
     Unknown = stream.ReadSByte();
     WorldHeight = stream.ReadByte();
     MaxPlayers = stream.ReadByte();
 }
Beispiel #27
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     DeltaX = stream.ReadSByte();
     DeltaY = stream.ReadSByte();
     DeltaZ = stream.ReadSByte();
 }
Beispiel #28
0
 public override void Read(BigEndianStream stream)
 {
     X = stream.ReadInt();
     Y = stream.ReadShort();
     Z = stream.ReadInt();
     Lines = new string[4];
     for (int i = 0; i < Lines.Length; i++)
         Lines[i] = stream.ReadString16(25);
 }
Beispiel #29
0
 public override void Read(BigEndianStream stream)
 {
     EntityId = stream.ReadInt();
     Unknown = stream.ReadBool();
     X = stream.ReadDoublePacked();
     Y = stream.ReadDoublePacked();
     Z = stream.ReadDoublePacked();
 }
Beispiel #30
0
 public override void Read(BigEndianStream stream)
 {
     PlayerId = stream.ReadInt();
     Animation = stream.ReadSByte();
 }