We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4499d9a commit 20d6695Copy full SHA for 20d6695
gamebro-gui.py
@@ -42,7 +42,11 @@
42
# Create window
43
screen = pygame.display.set_mode((WIDTH, HEIGHT))
44
pygame.display.set_caption("Gamebro Studio")
45
-pygame.display.set_icon(pygame.image.load(iconpath := os.path.join('assets', 'icon.png')))
+try:
46
+ pygame.display.set_icon(pygame.image.load(iconpath := os.path.join('assets', 'icon.png')))
47
+except (pygame.error, FileNotFoundError):
48
+ print(f"Error loading icon. Ensure the file exists.")
49
+ sys.exit()
50
try:
51
icon = PhotoImage(file=iconpath)
52
except _tkinter.TclError:
0 commit comments