Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import pygame
- import sys
- BLANCO = (255, 255, 255)
- ROJO = (255, 0, 0)
- MEDIDA_PANTALLA = (640, 480)
- def DibujarPantalla(pantalla):
- posicion = (320, 240)
- pygame.draw.circle(pantalla, ROJO, posicion, 239, 2)
- def EjecutarCiclo():
- pygame.init()
- pantalla = pygame.display.set_mode( MEDIDA_PANTALLA )
- reloj = pygame.time.Clock()
- while True:
- pantalla.fill(BLANCO)
- DibujarPantalla(pantalla)
- pygame.display.flip()
- tick = reloj.tick(60)
- if __name__ == "__main__":
- EjecutarCiclo()
- def Pelota(pantalla, posicion):
- pygame.draw.circle(pantalla, ROJO, posicion, 50)
- def DibujarPantalla(pantalla):
- posicion = (320, 240)
- Pelota(pantalla, posicion)
Advertisement
Add Comment
Please, Sign In to add comment