lordmauve / pgzero

A zero-boilerplate games programming framework for Python 3, based on Pygame.
https://pygame-zero.readthedocs.io/
GNU Lesser General Public License v3.0
530 stars 190 forks source link

pgzrun error #241

Closed Bigspoonguy closed 3 years ago

Bigspoonguy commented 3 years ago

Just trying to write/run super basic games in pygame zero, but keep getting the following error:

C:\Users\dave>pgzrun Desktop\Python Games\intro.py pygame 2.0.1 (SDL 2.0.14, Python 3.9.1) Hello from the pygame community. https://www.pygame.org/contribute.html Usage: pgzrun [options]

pgzrun: error: You must specify which module to run.

lordmauve commented 3 years ago

pgzrun Desktop\Python Games\intro.py

You will need to quote this, e.g.

pgzrun "Desktop\Python Games\intro.py"

Or use cd to switch to that directory.

fillwithjoy1 commented 3 years ago

Or you can add import pgzrun at the top of your code and pgzrun.go() at the end of your code