Fix bugs. Export state as FEN.