From 4cd87183ae4744f59d491d09bc059ea5da858af1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matija=20Gra=C4=8Danin?= <35041118+mgracanin@users.noreply.github.com> Date: Thu, 27 Jul 2023 22:54:34 +0200 Subject: [PATCH] Update __init__.py --- __init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/__init__.py b/__init__.py index c376bae..46dfe3f 100644 --- a/__init__.py +++ b/__init__.py @@ -19,7 +19,7 @@ async def main(): print(f"File {starwars_file_path} does not exist. \nMake sure file is in the same directory as this script and try again.") sys.exit(1) - ## Each frame is 67 columns by 14 rows + ## Each frame is 67 columns by 14 rows, so interating the file in chunks of LPS lines for i in range(0, len(podaci), LPS): print("\x1b[{}A\x1b[J{}".format(LPS, '\n'.join(podaci[i + 1:i + LPS]))) # \x1b[{}A\x1b[J move ESC char 14 lines await sleep(int(podaci[i]) * 67 / 1000) ## Delay = 67