When you press certain buttons in my game (a 2d puzzle platformer), the tilemap (but character and maybe enemies and objects) is flipped horizontal or vertically.
What i do was: flip the tilemap and move by 1920, 1080 or both all entities and the camera to their respective original positions adapted to the tilemap one (scale -1), but still the coordinates doesn't fit with tilemap ones (meanwhile the tiles in the same y (visually) as the player are = 2, my character is -3).