#!/bin/python
import pygame, sys
import random
import math
WHITE = (255, 255, 255)
pygame.init()
sc = pygame.display.set_mode((500, 500))
pygame.display.set_caption("Полотно на pygame")
sc.fill((125,125,125))
x1 = random.randint(50,500)
y1 = random.randint(50,500)
while True:
for event in pygame.event.get():
if event.type == pygame.QUIT:
pygame.quit()
sys.exit()
x1 = random.randint(50,500)
y1 = random.randint(50,500)
pygame.draw.circle(sc, (255,0,255), (int(x1), int(y1)),random.randint(5,25))
pygame.display.flip()
|