"Conjunto de módulos python para desenvolver jogos."
Esses módulos fornecem acesso a diversos dispositivos de hardware como teclado, mouse, som, vídeo e etc.
http://www.pygame.org/download.shtml
# coding: utf-8
import pygame
pygame.init()
WINDOW_HEIGHT, WINDOW_WIDTH = 800, 600
screen = pygame.display.set_mode((WINDOW_HEIGHT, WINDOW_WIDTH))
pygame.display.set_caption('Snake Game')
# coding: utf-8
import pygame
pygame.init()
WINDOW_HEIGHT, WINDOW_WIDTH = 800, 600
screen = pygame.display.set_mode((WINDOW_HEIGHT, WINDOW_WIDTH))
pygame.display.set_caption('Snake Game')
color_blue = (0, 0, 255)
surface = pygame.Surface([60, 60])
surface.fill(color_blue)
screen.blit(surface, (10, 10))
pygame.display.update()
while True:
clock.tick(16)
screen.fill((255, 255, 255))
for event in pygame.event.get():
if event.type == pygame.QUIT:
pygame.quit()
sys.exit(0)
if event.type == KEYDOWN:
if event.key == K_LEFT:
rect.x -= 10
if event.key == K_RIGHT:
rect.x += 10
if event.key == K_UP:
rect.y -= 10
if event.key == K_DOWN:
rect.y += 10
screen.blit(surface, rect)
pygame.display.update()
http://www.pygame.org/hifi.html
http://programeempython.blog.br/
http://www.gamesindustry.biz/jobs
https://github.com/IuryAlves
iuryalves20@gmail.com