Python Forum
Issue with Pygame opening my Sprite png
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Issue with Pygame opening my Sprite png
#2
Just a sanity check try running this just before loading the image
print(os.getcwd())
Are you running this with an IDE? If so i would run it via terminal/command prompt and see if it is an IDE related issue. IDE's can change the current working directory than what you think it might be.

you can try using the absolute path
Quote:Change pygame.image.load('/images/xxx') to

pygame.image.load('/Users/xxx/..../images/xxxx')

What was your pygame installation process? Did you happen to compile pygame without a dependency or did you use pip?
Recommended Tutorials:
Reply


Messages In This Thread
RE: Issue with Pygame opening my Sprite png - by metulburr - Feb-20-2019, 10:03 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020