Explorar o código

Prevent animation from scrolling terminal

DricomDragon %!s(int64=5) %!d(string=hai) anos
pai
achega
313eb38888
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      main.cc

+ 2 - 0
main.cc

@@ -319,6 +319,7 @@ class World
 				markOne(tile, DISCOVERED);
 				display();
 				usleep(DEFAULT_ANIMATION_DELAY);
+				cout << "\033[" << h << 'A';
 			}
 
 			if (exitFound)
@@ -326,6 +327,7 @@ class World
 					markOne(tile, TRACE);
 					display();
 					usleep(DEFAULT_ANIMATION_DELAY);
+					cout << "\033[" << h << 'A';
 				}
 		}