#!/bin/python
import pygame, sys
import random
green = (0, 255, 0)
blue = (0, 0, 128)
red = (255, 0, 0)
pygame.init()
sc = pygame.display.set_mode((640, 500))
pygame.display.set_caption("Супер машинка на pygame")
while True:
sc.fill((125,125,125))
for event in pygame.event.get():
if event.type == pygame.QUIT:
pygame.quit()
sys.exit()
pygame.draw.line(sc, (255, 255, 255),[10, 30], [290, 30], 3)
pygame.draw.line(sc, (255, 255, 255),[10, 30], [10, 250], 3)
pygame.draw.line(sc, (255, 255, 255),[290, 30], [490, 250], 3)
pygame.draw.rect(sc, (255, 255, 255), (0,150,550,100))
pygame.draw.circle(sc, red, (100, 250), 50)
pygame.draw.circle(sc, red, (350, 250), 50)
pygame.draw.circle(sc, blue, (120, 240), 10)
pygame.display.flip()
|