def __init__(self, name, description, strength, damage, max_health, defense, occupation, magic, magic_points): super().__init__(name, description, strength, damage, max_health) self.__defense = Character_Helper_Functions.set_attributes(defense, "Defense") self.__occupation = Character_Helper_Functions.check_enum(Occupations, occupation) self.__has_magic = Character_Helper_Functions.check_boolean(magic) if self.__has_magic: self.__magic = Character_Helper_Functions.set_attributes(magic_points, "Magic Points")
def __init__(self, name, description, strength, damage, max_health): self.__name = name self.__description = description self.__strength = Character_Helper_Functions.set_attributes( strength, "strength") self.__damage = Character_Helper_Functions.set_attributes( damage, "Damage") self.__max_health = Character_Helper_Functions.set_attributes( max_health, "Max health") self.__health = Character_Helper_Functions.set_attributes( max_health, "health")
def __init__(self, name, description, strength, damage, max_health, level, magic, magic_points, experience): super().__init__(name, description, strength, damage, max_health) self.__level = Character_Helper_Functions.set_attributes( level, "Level") self.__experience = Character_Helper_Functions.set_attributes( experience, "Experience") self.__has_magic = Character_Helper_Functions.check_boolean(magic) if self.__has_magic: self.__magic = Character_Helper_Functions.set_attributes( magic_points, "Magic Points")
def set_max_health(self, max_health): self.__max_health = Character_Helper_Functions.set_attributes( max_health, "Max Health") self.__health = Character_Helper_Functions.set_attributes( max_health, "health")
def set_damage(self, damage): self.__damage = Character_Helper_Functions.set_attributes( damage, "Damage")
def set_strength(self, strength): self.__strength = Character_Helper_Functions.set_attributes( strength, "strength")
def set_occupation(self, occupation): self.__occupation = Character_Helper_Functions.check_enum(Occupations, occupation)
def set_defense(self, defense): self.__defense = Character_Helper_Functions.set_attributes(defense, "Defense")
def set_magic(self, magic_points): if self.__has_magic: self.__magic = Character_Helper_Functions.set_attributes(magic_points, "Magic Points")
def set_has_magic(self, magic): self.__has_magic = Character_Helper_Functions.check_boolean(magic)
def set_experience(self, experience): self.__experience = Character_Helper_Functions.set_attributes( experience, "Experience")
def set_level(self, level): self.__level = Character_Helper_Functions.set_attributes( level, "Level")