37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
from Skill import Skill
|
|
class Character:
|
|
def __init__(self, max_hp: int):
|
|
self.Body = Skill("Body")
|
|
self.Mental = Skill("Mental")
|
|
self.Profound = Skill("Profound")
|
|
self.Aura = Skill("Aura")
|
|
self.Setting = Skill("Setting")
|
|
self.NaturalVisualDescription = ""
|
|
self.WithBelongsVisualDescription = ""
|
|
self.Personality = ""
|
|
self.Ideals = ""
|
|
self.Bonds = ""
|
|
self.Flaws = ""
|
|
self.Inventory = "" #This should probably be a list of class items
|
|
self.Backstory = ""
|
|
self.Armor = ""
|
|
self.LegalTender = 0
|
|
self.MaxHp = 0
|
|
self.CurrentHp = 0
|
|
def spend_money(self, amount_to_spend : int ) -> bool:
|
|
if amount_to_spend <= 0:
|
|
return False
|
|
elif self.LegalTender >= amount_to_spend:
|
|
self.LegalTender -= amount_to_spend
|
|
return True
|
|
else:
|
|
return False
|
|
def earn_money(self, amount_earned: int) -> bool:
|
|
if amount_earned <= 0:
|
|
return False
|
|
else:
|
|
self.LegalTender += amount_earned
|
|
return True
|
|
|
|
|