import pygame from pygame.locals import * import sys pygame.init() displaysurface = pygame.display.set_mode((400,600)) mySurface1 = pygame.Surface((50,50)) mySurface2 = pygame.Surface((50,100)) mySurface3 = pygame.Surface((100,50)) mySurface1.fill( (0, 255, 0) ) mySurface2.fill( (255, 0, 0) ) mySurface3.fill( (0, 0, 255) ) while True: #main game loop for event in pygame.event.get(): if event.type == QUIT: pygame.quit() sys.exit() displaysurface.blit(mySurface1,(150,150)) displaysurface.blit(mySurface2,(400,150)) displaysurface.blit(mySurface3,(200,200)) pygame.display.update()