Just started playing with pygame and when creating a new projetc in Pycharm, i'm not able to import pygame. From what i've read i have pygame intalled correctly (running Powershell in the pygame project folder PS C:\Users\54294\PycharmProjects\pygame> pip install pygame==2.1.2
Requirement already satisfied: pygame==2.1.2 in c:\users\54294\appdata\local\programs\python\python311\lib\site-packages (2.1.2))
Now, whenever i want to "import pygame" inside the main.py file, it says
Traceback (most recent call last):
File "C:\Users\54294\PycharmProjects\pygame\main.py", line 1, in
import pygame
ModuleNotFoundError: No module named 'pygame'.
Got it to work once, but refactored the folder and it stopped working.
I've tried:
-running the import pygame and installing the package
-going to File>settings>Python Interpreter and installing the pakage (specifyinhand not specifying version)
-installing pygame as pygame and pygame==2.1.2 from Powershell inside venv\Scripts
Nothing seems to work...
Pygame works fine in the Pythin IDE that comes form isntalling Python (
import pygame
pygame 2.1.2 (SDL 2.0.18, Python 3.11.0)
Hello from the pygame community. https://www.pygame.org/contribute.html).
I'd Apreciate any help
I've tried:
-running the import pygame and installing the package
-going to File>settings>Python Interpreter and installing the pakage (specifyinhand not specifying version)
-installing pygame as pygame and pygame==2.1.2 from Powershell inside venv\Scripts
Nothing seems to work...