| @@ -24,6 +24,8 @@ class Main: | |||||
| screen: pygame.Surface = pygame.display.set_mode ((1024, 768)) | screen: pygame.Surface = pygame.display.set_mode ((1024, 768)) | ||||
| balloon = pygame.transform.scale (pygame.image.load ('talking.png'), | balloon = pygame.transform.scale (pygame.image.load ('talking.png'), | ||||
| (1024, 384)) | (1024, 384)) | ||||
| if goatoh_mode: | |||||
| balloon = pygame.transform.flip (balloon, False, True) | |||||
| pygame.mixer.init (frequency = 44100) | pygame.mixer.init (frequency = 44100) | ||||
| noon = pygame.mixer.Sound ('noon.wav') | noon = pygame.mixer.Sound ('noon.wav') | ||||
| mumumumu = pygame.mixer.Sound ('mumumumu.wav') | mumumumu = pygame.mixer.Sound ('mumumumu.wav') | ||||
| @@ -63,7 +65,8 @@ class Main: | |||||
| with open ('log.txt', 'a') as f: | with open ('log.txt', 'a') as f: | ||||
| f.write (f'{datetime.now ()}\t{json.dumps (chat_item.__dict__)}\t{answer}\n') | f.write (f'{datetime.now ()}\t{json.dumps (chat_item.__dict__)}\t{answer}\n') | ||||
| screen.blit (balloon, (0, 0)) | |||||
| screen.blit (balloon, (0, 384) if goatoh_mode else (0, 0)) | |||||
| screen.blit ( | screen.blit ( | ||||
| user_font.render ( | user_font.render ( | ||||
| '> ' + (message | '> ' + (message | ||||
| @@ -74,7 +77,7 @@ class Main: | |||||
| + '...')), | + '...')), | ||||
| True, | True, | ||||
| (0, 0, 0)), | (0, 0, 0)), | ||||
| (120, 70)) | |||||
| (120, 70 + 384) if goatoh_mode else (120, 70)) | |||||
| screen.blit ( | screen.blit ( | ||||
| nizika_font.render ( | nizika_font.render ( | ||||
| (answer | (answer | ||||
| @@ -82,7 +85,7 @@ class Main: | |||||
| else CommonModule.mid_by_full (answer, 0, 16)), | else CommonModule.mid_by_full (answer, 0, 16)), | ||||
| True, | True, | ||||
| (192, 0, 0)), | (192, 0, 0)), | ||||
| (100, 150)) | |||||
| (100, 150 + 384) if goatoh_mode else (100, 150)) | |||||
| if CommonModule.len_by_full (answer) > 16: | if CommonModule.len_by_full (answer) > 16: | ||||
| screen.blit ( | screen.blit ( | ||||
| nizika_font.render ( | nizika_font.render ( | ||||
| @@ -93,7 +96,7 @@ class Main: | |||||
| + '...')), | + '...')), | ||||
| True, | True, | ||||
| (192, 0, 0)), | (192, 0, 0)), | ||||
| (100, 200)) | |||||
| (100, 200 + 384) if goatoh_mode else (100, 200)) | |||||
| pygame.display.update () | pygame.display.update () | ||||