From 2b244e04d211590565532a45dc6d71e4b6bbfa23 Mon Sep 17 00:00:00 2001 From: prabathbr <60564552+prabathbr@users.noreply.github.com> Date: Tue, 15 Feb 2022 03:25:50 +1100 Subject: [PATCH] # Fix for issue : https://github.com/Talendar/flappy-bird-gym/issues/3 # Fix for issue : https://github.com/Talendar/flappy-bird-gym/issues/3 by prabathbr (https://github.com/prabathbr/) import os from pathlib import Path _BASE_DIR = Path(os.path.dirname(os.path.realpath(__file__))).parent ASSETS_DIR = str(_BASE_DIR / "flappy_bird_gym/assets") --- flappy_bird_gym/original_game.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/flappy_bird_gym/original_game.py b/flappy_bird_gym/original_game.py index 3b9c778..c9a39bb 100644 --- a/flappy_bird_gym/original_game.py +++ b/flappy_bird_gym/original_game.py @@ -12,7 +12,12 @@ import pygame from pygame.locals import * -ASSETS_DIR = "./flappy_bird_gym/assets" +# Fix for issue : https://github.com/Talendar/flappy-bird-gym/issues/3 by prabathbr (https://github.com/prabathbr/) +import os +from pathlib import Path +_BASE_DIR = Path(os.path.dirname(os.path.realpath(__file__))).parent +ASSETS_DIR = str(_BASE_DIR / "flappy_bird_gym/assets") + FPS = 30 SCREEN_WIDTH = 288