install pygame
Shell
# on your terminal :
pip install pygame
# check if pygame run :
py -m pygame.examples.aliens
# if a window is open -> pygame is correctly installed import pygame
pygame.init()
win = pygame.display.set_mode((500,500))
pygame.display.set_caption("First Game")
x = 50
y = 50
width = 40
height = 60
vel = 5
run = True
while run:
pygame.time.delay(100) # This will delay the game the given amount of milliseconds. In our casee 0.1 seconds will be the delay
for event in pygame.event.get(): # This will loop through a list of any keyboard or mouse events.
if event.type == pygame.QUIT: # Checks if the red button in the corner of the window is clicked
run = False # Ends the game loop
pygame.quit() # If we exit the loop this will execute and close our game
# Type this in the Command Prompt (For Windows) : pip install pygame
# Then head on to your text editor and type :
import pygamepy -m pip install -U pygame --user
pip install pygamepy -m pygame.examples.aliens
Also in Shell:
- Title
- install bootstrap vue laravel 7
- Category
- Shell
- Title
- how to install gatsby gatsby-plugin-manifest
- Category
- Shell
- Title
- connect to windows 10 remote desktop from ubuntu
- Category
- Shell
- Title
- install deno
- Category
- Shell
- Title
- snap store android studio
- Category
- Shell
- Title
- show applications shortcut ubuntu
- Category
- Shell
- Title
- error: src refspec master does not match any. git
- Category
- Shell
- Title
- tree process linux commnad
- Category
- Shell
- Title
- edit default port for linux server
- Category
- Shell
- Title
- shell script variable
- Category
- Shell
- Title
- install flask
- Category
- Shell
- Title
- chmode ubuntu
- Category
- Shell
- Title
- gitlab docker runner
- Category
- Shell
- Title
- apache basic auth setup
- Category
- Shell
- Title
- calcul md5 fichier linux
- Category
- Shell
- Title
- linux move everything in a directory to another directory
- Category
- Shell
- Title
- bash edit prompt display appearance
- Category
- Shell
- Title
- github undo last pushed commit
- Category
- Shell
- Title
- npm list global packages
- Category
- Shell
- Title
- linux copy
- Category
- Shell
- Title
- mac cleanup github
- Category
- Shell
- Title
- find text in any file linux
- Category
- Shell
- Title
- update ubuntu
- Category
- Shell
- Title
- linux screen detach
- Category
- Shell
- Title
- uninstall g2o
- Category
- Shell
- Title
- job('DSL-Tutorial-1-Test') { scm { git('git://github.com/quidryan/aws-sdk-test.git') } triggers { scm('H/15 * * * *') } steps { maven('-e clean test') } }
- Category
- Shell
- Title
- cosmicjs
- Category
- Shell
- Title
- date command in linux
- Category
- Shell
- Title
- git show stashes
- Category
- Shell
- Title
- fatal: could not read Username for 'https://github.com': Device not configured push crontab
- Category
- Shell
- Title
- wheres i3 config file
- Category
- Shell
- Title
- ubuntu command line replace word in files
- Category
- Shell
- Title
- crop video from specific time to specific time ffmpeg
- Category
- Shell
- Title
- boolean constants in bash
- Category
- Shell
- Title
- how to use gitignore to ignore a folder
- Category
- Shell
- Title
- start mariadb on linux terminal
- Category
- Shell
- Title
- shared folder virtualbox ubuntu
- Category
- Shell
- Title
- install spotify ubuntu snap
- Category
- Shell
- Title
- open pdf command line linux
- Category
- Shell
- Title
- edit branch name git
- Category
- Shell
- Title
- docker exc into mongo shell
- Category
- Shell
- Title
- install vscode ubuntu command line
- Category
- Shell
- Title
- "at" ubuntu script dschedule
- Category
- Shell
- Title
- install jupyter notebook
- Category
- Shell
- Title
- bash check in gem is installed
- Category
- Shell
- Title
- view host entires mac terminal
- Category
- Shell
- Title
- mostrare i grafici matplotlib sulla shell python
- Category
- Shell
- Title
- install homebrew on mac
- Category
- Shell
- Title
- increase no of watchers
- Category
- Shell
- Title
- intel pinning threads
- Category
- Shell
- Title
- command to find out my git head version
- Category
- Shell
- Title
- display folder of path linux bashrc
- Category
- Shell
- Title
- git command to create a branch
- Category
- Shell
- Title
- ldap query powershell
- Category
- Shell
- Title
- linux find files multiple
- Category
- Shell
- Title
- Pyrit download command for linux
- Category
- Shell
- Title
- edit files from terminal linux
- Category
- Shell
- Title
- react native blank screen linux
- Category
- Shell
- Title
- linux restrict process network access
- Category
- Shell
- Title
- install node ubuntu
- Category
- Shell
- Title
- netstat install
- Category
- Shell
- Title
- install phpmyadmin ubuntu 18.04
- Category
- Shell
- Title
- grep command
- Category
- Shell
- Title
- install automapper asp.net core mvc
- Category
- Shell
- Title
- how to change permissions on a file in linux
- Category
- Shell
- Title
- linux extract tgz
- Category
- Shell
- Title
- run powershell script from wsl bash
- Category
- Shell
- Title
- docker build
- Category
- Shell
- Title
- env variable bash
- Category
- Shell
- Title
- convert excel to csv command line linux
- Category
- Shell
- Title
- how to avoid some files changes to not come in git status
- Category
- Shell
- Title
- install expo cli windows
- Category
- Shell
- Title
- restart service linux crontab
- Category
- Shell
- Title
- how to switch branches in git
- Category
- Shell
- Title
- exa ls command
- Category
- Shell
- Title
- how to create folder in github
- Category
- Shell
- Title
- how to get stashed on git
- Category
- Shell
- Title
- terminal delete directory not empty
- Category
- Shell
- Title
- ubuntu install brew
- Category
- Shell
- Title
- wtmp is not readable
- Category
- Shell
- Title
- install poetry
- Category
- Shell
- Title
- install concrete 5 on ec2 instance
- Category
- Shell
- Title
- git stas hauntracked files
- Category
- Shell
- Title
- rustup
- Category
- Shell
- Title
- git delete repository command line
- Category
- Shell
- Title
- bash find file with text
- Category
- Shell
- Title
- npm install cli vue
- Category
- Shell
- Title
- createa. branch off of development git
- Category
- Shell
- Title
- ionic publish
- Category
- Shell
- Title
- java project ideas
- Category
- Shell
- Title
- how to stop a web server linux
- Category
- Shell
- Title
- install redux-thunk
- Category
- Shell
- Title
- install tqdm
- Category
- Shell
- Title
- install composer package from github
- Category
- Shell
- Title
- linux version command
- Category
- Shell
- Title
- restart bluetooth ubuntu
- Category
- Shell
- Title
- install node modules from package.json
- Category
- Shell
- Title
- bash ls all subdirectories
- Category
- Shell
- Title
- linux command to check memory usage in percentage
- Category
- Shell
- Title
- ubuntu install apache2
- Category
- Shell