mit env datei
This commit is contained in:
parent
efa15cbca3
commit
2b6a708f6c
10
.env
10
.env
@ -1,6 +1,6 @@
|
||||
|
||||
TITLE = "Moon"
|
||||
FPS = 60
|
||||
POSITION_MOON = (0, -150)
|
||||
SIZE = (640, 400)
|
||||
THETA = 0.01
|
||||
TITLE="Moon"
|
||||
FPS=60
|
||||
POSITION_MOON=0,-150
|
||||
SIZE=640,400
|
||||
THETA=0.01
|
||||
@ -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()
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user