protected override void OnRead(Server.Core.Stream.ByteBuffer buffer)
        {
            Status = (byte)buffer.ReadByte();
            X      = buffer.ReadInt();
            Y      = (byte)buffer.ReadByte();
            Z      = buffer.ReadInt();
            Face   = (byte)buffer.ReadByte();

            MinecraftServer.Core.Network.Server.ViewModel.Warning("Player Dig : Status = " + Status + ", Block(" + X + ", " + Y + ", " + Z + "), Face = " + Face);
        }
Esempio n. 2
0
        protected override void OnRead(Server.Core.Stream.ByteBuffer buffer)
        {
            _x         = buffer.ReadInt();
            _y         = (byte)buffer.ReadByte();
            _z         = buffer.ReadInt();
            _direction = (byte)buffer.ReadByte();

            if (_direction == 0)
            {
                _y--;
            }
            else if (_direction == 1)
            {
                _y++;
            }
            else if (_direction == 2)
            {
                _z--;
            }
            else if (_direction == 3)
            {
                _z++;
            }
            else if (_direction == 4)
            {
                _x--;
            }
            else if (_direction == 5)
            {
                _x++;
            }

            _blockID = buffer.ReadShort();
            if (_blockID < 0)
            {
                return;
            }
            MinecraftServer.Core.Network.Server.ViewModel.Warning("Block Placement Coord(" + _x + ", " + _y + ", " + _z + ")");
            _itemCount  = (byte)buffer.ReadByte();
            _itemDamage = buffer.ReadShort();
            _NBTLength  = buffer.ReadShort();
        }
Esempio n. 3
0
 protected override void OnRead(Server.Core.Stream.ByteBuffer stream)
 {
     ActionID = (byte)stream.ReadByte();
 }
Esempio n. 4
0
 protected override void OnRead(Server.Core.Stream.ByteBuffer stream)
 {
     stream.ReadByte();
     stream.ReadFloat();
     stream.ReadFloat();
 }
Esempio n. 5
0
 protected override void OnRead(Server.Core.Stream.ByteBuffer stream)
 {
     WindowId = (byte)stream.ReadByte();
 }