diff --git a/.env b/.env index 47063b6..aafe98b 100644 --- a/.env +++ b/.env @@ -1,6 +1,6 @@ -TITLE = "Moon" -FPS = 60 -POSITION_MOON = (0, -150) -SIZE = (640, 400) -THETA = 0.01 \ No newline at end of file +TITLE="Moon" +FPS=60 +POSITION_MOON=0,-150 +SIZE=640,400 +THETA=0.01 \ No newline at end of file diff --git a/lab_01/apollo.py b/lab_01/apollo.py index 7f5bf66..d0d5d9a 100644 --- a/lab_01/apollo.py +++ b/lab_01/apollo.py @@ -8,10 +8,10 @@ import pygame load_dotenv() title = str(os.getenv("TITLE")) -fps = str(os.getenv("FPS")) -size = str(os.getenv("SIZE")) -position_moon = str(os.getenv("POSITION_MOON")) -theta = str(os.getenv("THETA")) +fps = int(os.getenv("FPS")) +size = tuple(map(int, os.getenv("SIZE").split(','))) +theta = float(os.getenv("THETA")) +position_moon = tuple(map(int, os.getenv("POSITION_MOON").split(','))) WHITE = (255, 255, 255) @@ -59,6 +59,6 @@ class Apollo(Moon): if __name__ == "__main__": # created by me and only me - game = Apollo() + game = Apollo(title, fps, size, position_moon, theta) game.run()