diff --git a/src/entities/room.py b/src/entities/room.py index e24edb2..279804e 100644 --- a/src/entities/room.py +++ b/src/entities/room.py @@ -1,18 +1,22 @@ import uuid +from src.entities.cards import Cards + class Room: """ Room entity """ - def __init__(self, name): + def __init__(self, name, card_type="fibonacci"): """ Room entity initializer """ self.name = name self.uuid = None self.attendant = [] + self.card_type = card_type + self.cards = None self.create() def create(self): @@ -22,6 +26,8 @@ class Room: if not self.uuid: self.uuid = uuid.uuid1() + self.assign_cards() + return self def add_person(self, person: uuid.UUID): @@ -37,3 +43,14 @@ class Room: """ if person in self.attendant: self.attendant.remove(person) + + def assign_cards(self, card_type=None): + """ + Method to assign cards to a room + """ + if card_type: + self.cards = Cards(card_type) + else: + self.cards = Cards() + + return self.cards