so im using visual code, have python 3.8 installed and i installed the pygame package from powershell, yet when im writing pygame code it gives me the next error: " ModuleNotFoundError: No module named 'pygame' " tried everything for hours cant get it to work help will be apriciated <3 images:
Asked
Active
Viewed 137 times
1
-
Do you have multiple installations, or have you added and removed installations of python? – Axe319 May 05 '20 at 17:53
-
can you try running the code from command line with `python game.py`? Also, see my above comment. – Axe319 May 05 '20 at 18:06
-
See [ImportError: No module named 'pygame'](https://stackoverflow.com/questions/18317521/importerror-no-module-named-pygame) – Rabbid76 Dec 31 '21 at 14:18
1 Answers
0
What you also can do is to download pygame to your folder and than run the command python setup.py. This should install everythin correctly. If you still have trouble using pygame you can use the files in src_py from the download:
import init #instead of pygame.init()
I hope I was able to help.

Alex
- 12
- 1
- 2