import pygame import settings as s class Hand_screen(pygame.sprite.Sprite): def __init__(self): super().__init__() self.type = "hand_screen" self.w = s.SCREEN_WIDTH self.h = s.DOMINO_H * 1.5 self.color = (141, 111, 100) self.surf = pygame.Surface((self.w, self.h)) self.surf.fill(self.color) self.pos = (0, s.SCREEN_HEIGHT - self.h) self.rect = self.surf.get_rect(center=(self.pos[0] + s.SCREEN_WIDTH / 2, self.pos[1] + self.h / 2)) class Empty_domino(pygame.sprite.Sprite): def __init__(self, x, y): super().__init__() self.type = "domino" self.w = s.DOMINO_W * 1.1 self.h = s.DOMINO_H * 1.1 self.surf = pygame.Surface((self.w, self.h)) self.color = (50, 50, 50) self.surf.fill(self.color) self.rect = self.surf.get_rect(center=(x, y)) class Game_screen(pygame.sprite.Sprite): def __init__(self): super().__init__() self.type = "game_screen" self.w = s.SCREEN_WIDTH * 10 self.h = s.SCREEN_HEIGHT * 10 self.color = (230, 230, 230) self.surf = pygame.Surface((self.w, self.h)) self.surf.fill(self.color) self.rect = self.surf.get_rect(center=(self.w / 2, self.h / 2)) self.start_d_pos = (0, 0) self.d_edges = [] def blit_g_screen(self, screen): screen.blit(self.surf, self.rect)