Please make sure you already install the Anaconda.
I will create a virtual environment with anaconda and install the pygame in this virtual environment.
- First create a virtual environment called pygame and install the Python 3.6 version.
conda create --name pygame python=3.6
- Change to the pygame virtual environment.
conda activate pygame
- Install pygame
python3 -m pip install -U pygame --user
- Test pygame
python3 -m pygame.examples.aliens
If it works, you are ready to go!
Can you help me please? When I follow these instructions, Pygame is added to my base environment too, which I don't want. I know it's there because if I deactivate the new environment and run python I can still import pygame.