добавил файл task.py
This commit is contained in:
35
task1.py
Normal file
35
task1.py
Normal file
@@ -0,0 +1,35 @@
|
||||
import pygame
|
||||
from pygame.draw import *
|
||||
|
||||
pygame.init()
|
||||
|
||||
FPS = 30
|
||||
screen = pygame.display.set_mode((1000, 1000))
|
||||
a = 30
|
||||
dx = 80
|
||||
y = 450
|
||||
|
||||
circle(screen, (210, 210, 80), (500, 500), 200)
|
||||
circle(screen, (255, 255, 255), (500, 500), 200, 2)
|
||||
circle(screen, (255, 0, 0), (500 - dx, y), a)
|
||||
circle(screen, (255, 0, 0), (500 + dx, y), a)
|
||||
circle(screen, (0, 0, 0), (500 - dx, y), 10)
|
||||
circle(screen, (0, 0, 0), (500 + dx, y), 10)
|
||||
circle(screen, (255, 255, 255), (500 - dx, y), a, 2)
|
||||
circle(screen, (255, 255, 255), (500 + dx, y), a, 2)
|
||||
|
||||
polygon(screen, (0, 0, 255), [(100, 120), (120, 140), (140, 120), (120, 100)])
|
||||
|
||||
|
||||
|
||||
pygame.display.update()
|
||||
clock = pygame.time.Clock()
|
||||
finished = False
|
||||
|
||||
while not finished:
|
||||
clock.tick(FPS)
|
||||
for event in pygame.event.get():
|
||||
if event.type == pygame.QUIT:
|
||||
finished = True
|
||||
|
||||
pygame.quit()
|
||||
Reference in New Issue
Block a user