def toggle_show_fps(self, key):
"""Press f5 to turn on/off displaying the framerate in the caption."""
if key == pg.K_F5:
self.show_fps = not self.show_fps
if not self.show_fps:
pg.display.set_caption(self.caption)
评论列表
文章目录