def _write(self, text: str, textColor: pygame.Color, size : ctypes.c_int16, x: ctypes.c_int16, y: ctypes.c_int16, center: bool = False):
visual = pygame.font.SysFont("Candara", size)
surface = visual.render(text, True, textColor)
if not center:
rectangle = surface.get_rect(x = x, y = y)
else:
rectangle = surface.get_rect(centerx = x, centery = y)
self.MAIN.blit(surface, rectangle)
评论列表
文章目录