Implement the monocle of truth, closes #62

This commit is contained in:
Yohann D'ANELLO
2021-01-08 15:48:12 +01:00
parent 1270640619
commit a497d08f31
10 changed files with 97 additions and 49 deletions

View File

@ -86,8 +86,8 @@ class Item(Entity):
"""
Returns the list of all item classes.
"""
return [BodySnatchPotion, Bomb, Heart, Shield, Sword,
Chestplate, Helmet, RingCritical, RingXP]
return [BodySnatchPotion, Chestplate, Bomb, Heart, Helmet, Monocle,
Shield, Sword, RingCritical, RingXP]
def be_sold(self, buyer: InventoryHolder, seller: InventoryHolder) -> bool:
"""
@ -453,3 +453,9 @@ class RingXP(Ring):
experience: float = 2, *args, **kwargs):
super().__init__(name=name, price=price, experience=experience,
*args, **kwargs)
class Monocle(Item):
def __init__(self, name: str = "monocle", price: int = 10,
*args, **kwargs):
super().__init__(name=name, price=price, *args, **kwargs)