diff --git a/log.txt b/log.txt index bf4eef4..b70d6d4 100644 --- a/log.txt +++ b/log.txt @@ -1,6 +1,6 @@ -13:24:17: Loading game... -13:24:17: Loading images... -13:24:17: Setup fonts... -13:24:17: Get git revision hash... -13:24:17: Git-Hash: fb55785 -13:24:32: Log closed! +13:35:44: Loading game... +13:35:44: Loading images... +13:35:44: Setup fonts... +13:35:44: Get git revision hash... +13:35:44: Git-Hash: 7598878 +13:36:10: Log closed! diff --git a/test.py b/test.py index 47b297a..b2ac583 100644 --- a/test.py +++ b/test.py @@ -17,7 +17,7 @@ pygame.mouse.set_visible(True) RENDERING_SIZE = (1024,768) WINDOWED_DEF_SIZE = (1024,768) #pygame.key.set_repeat(1, 30) -window = pygame.display.set_mode((2440,1200), pygame.FULLSCREEN) +window = pygame.display.set_mode((RENDERING_SIZE)) screen = pygame.Surface(RENDERING_SIZE) #screen = pygame.display.set_mode((1024,768)) #TODO Add fullscreen mode @@ -87,6 +87,9 @@ while(gamestate): gamestate = False if(event.type == pygame.KEYDOWN and event.key == pygame.K_ESCAPE): gamestate = False + #Push F10 for fullscreen-mode + if(event.type == pygame.KEYDOWN and event.key == pygame.K_F10): + pygame.display.set_mode(RENDERING_SIZE, pygame.FULLSCREEN) player1.handle_input(event) player2.handle_input(event) @@ -96,7 +99,6 @@ while(gamestate): if(player1.keymap["right"] == True and player1.pos_x <= (screen.get_size()[0]-player1.width)): player1.move("right") #print("rechts") - if(player2.keymap["left"] == True and player2.pos_x > 0): player2.move("left") #print("links") @@ -220,8 +222,11 @@ while(gamestate): screen.blit(hash_label, (25, screen.get_size()[1] -25)) frametime = clock.get_time() + #Scales the mainsurface scaled_win = pygame.transform.smoothscale(screen, window.get_size()) + #Blits the mainsurface to the mainwindow window.blit(scaled_win, (0, 0)) + #if(mouse_pos <= (image.topleft+image.size) and mouse_pos >= image.topleft): # print("HIIIIITTT!!!!") frametime = 0