From 9d90fd0a21d9d1e25368284c137053d105dda8e7 Mon Sep 17 00:00:00 2001 From: Armaan Bhojwani Date: Sun, 31 Jan 2021 16:46:43 -0500 Subject: [PATCH] Add __init__ functions to the classes --- lightcards/deck.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lightcards/deck.py b/lightcards/deck.py index e3ef5c5..b0822a9 100644 --- a/lightcards/deck.py +++ b/lightcards/deck.py @@ -3,7 +3,9 @@ class Card(list): """Card extends the list class, and adds ability to star them.""" - starred = False + def __init__(self, inp): + super().__init__(inp) + self.starred = False def unStar(self): self.starred = False @@ -29,8 +31,9 @@ class Card(list): class Status(): """The status class keeps track of where in the deck the user is""" - index = 0 - side = 0 + def __init__(self): + self.index = 0 + self.side = 0 def forward(self, stack): if not self.index == len(stack): -- 2.39.2