@Override
 public void decodeInto(ChannelHandlerContext ctx, ByteBuf buffer) {
   super.decodeInto(ctx, buffer);
   this.dir = ForgeDirection.getOrientation(buffer.readInt());
 }
 @Override
 public void encodeInto(ChannelHandlerContext ctx, ByteBuf buffer) {
   super.encodeInto(ctx, buffer);
   buffer.writeInt(dir.ordinal());
 }