Exemplo n.º 1
0
 protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
 {
     buffer.WriteVarint(ID);
     buffer.WriteInt(Dimension);
     buffer.WriteByte(Difficulty);
     buffer.WriteByte(Gamemode);
     buffer.WriteString(LevelType);
 }
Exemplo n.º 2
0
 protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
 {
     MinecraftServer.Core.Network.Server.ViewModel.Warning("Block Change : Block(" + X + ", " + Y + ", " + Z + "), NewID = " + BlockID);
     buffer.WriteVarint(ID);
     buffer.WriteInt(X);
     buffer.WriteByte(Y);
     buffer.WriteInt(Z);
     buffer.WriteVarint(BlockID);
     buffer.WriteByte(BlockMeta);
 }
Exemplo n.º 3
0
        protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
        {
            client.PlayerMetadata.GameMode = 1;

            buffer.WriteVarint(ID);
            buffer.WriteInt(4);
            buffer.WriteByte(1);
            buffer.WriteByte(0);
            buffer.WriteByte(1);
            buffer.WriteByte(32);
            buffer.WriteString("default");
        }
 protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
 {
     buffer.WriteVarint(ID);
     buffer.WriteVarint(PlayerEntityId);
     buffer.WriteString(PlayerUUID);
     buffer.WriteString(PlayerName);
     buffer.WriteFixedPoint(PlayerX);
     buffer.WriteFixedPoint(PlayerY);
     buffer.WriteFixedPoint(PlayerZ);
     buffer.WriteByte(PlayerYaw);
     buffer.WriteByte(PlayerPitch);
     buffer.WriteShort(CurrentItem);
     buffer.WriteByte((3 << 5) | 6);
     buffer.WriteFloat(Health);
     buffer.WriteByte(0x7F);
 }
 protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
 {
     buffer.WriteVarint(ID);
     buffer.WriteByte((byte)Entities.Count);
     foreach (int i in Entities)
     {
         buffer.WriteInt(i);
     }
 }
Exemplo n.º 6
0
        protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
        {
            byte flag = 0x01 | 0x08 | 0x02 | 0x04;

            buffer.WriteVarint(ID);
            buffer.WriteByte(flag);
            buffer.WriteFloat(0.1f);
            buffer.WriteFloat(1.0f);
        }
Exemplo n.º 7
0
 protected override void OnBeforeWrite(Network.Client client, Server.Core.Stream.ByteBuffer buffer)
 {
     buffer.WriteVarint(ID);
     buffer.WriteByte(0);
     buffer.WriteShort(0);
 }