public void SendSetBlock(Vector3 position, BlockSetMode mode, int type) { PacketClientSetBlock p = new PacketClientSetBlock() { X = (int)position.X, Y = (int)position.Y, Z = (int)position.Z, Mode = (mode == BlockSetMode.Create ? (byte)1 : (byte)0), BlockType = type }; SendPacket(Serialize(new PacketClient() { PacketId = ClientPacketId.SetBlock, SetBlock = p })); }
public void SendSetBlock(Vector3 position, BlockSetMode mode, int type, int materialslot) { PacketClientSetBlock p = new PacketClientSetBlock() { X = (int)position.X, Y = (int)position.Y, Z = (int)position.Z, Mode = mode, BlockType = type, MaterialSlot = materialslot, }; SendPacket(Serialize(new PacketClient() { PacketId = ClientPacketId.SetBlock, SetBlock = p })); }