I'm reading a Python Programming text where it's creating a scene within a game with the following code:
class Death(Scene):
quips = [
"You died. You kinda suck at this.",
"Your Mom would be proud...if she were smarter.",
"Such a luser.",
"I have a small puppy that's better at this.",
"You're worse than your Dad's jokes."
]
def enter(self):
print(Death.quips[randint(0, len(self.quips)-1)])
My question is just over the last line. What's the difference when using a specific class name, in this case Death.quips as opposed to self.quips. The latter is how I've always seen it but it's used differently here. My first thought was maybe it bypasses needing to first create an object, but in this example self.quips requires the object anyways.