Made some changes to my test branch

@meshy well i made a comment anyway
If you make self.pieces a list instead of a dictionary, then this can become `random.choice(self.pieces)`.