def build_character_default(cls): assert type(cls) is type, "Must call as classmethod" """Construct a character to play with""" ######## # BUILD HENRI (sort of) ####### c = Character() c.base.str_score = 19 c.base.dex_score = 12 c.base.con_score = 13 c.base.cha_score = 14 c.BAB = 5 greatsword = Weapon("Greatsword", Attack(atk=+0, dmg_roll=DamageRoll.fromString("2d6"), crit_range=[19,20], crit_mult=2, two_handed=True)) #c.equipment.main_hand = greatsword # Add in dual-wield for testing tidewater_cutless = Weapon("Tidewater Cuttless +1", Attack(atk=+1, dmg_roll=DamageRoll.fromString("1d6+1"), crit_range=[18,19,20], crit_mult=2)) c.equipment.main_hand = tidewater_cutless masterwork_handaxe = Weapon("Masterwork Handaxe", Attack(atk=1, dmg_roll=DamageRoll.fromString("1d6"), crit_range=[20,], crit_mult=3)) c.equipment.off_hand = masterwork_handaxe cls.c = c # Buffs cls.possible_buffs_list = \ [Buff('Favored Enemy (Human)',4,4), Buff('Favored Enemy (Monstrous Humanoid)',2,2), Buff('Bless',atk_mod=1), Buff('Prayer',atk_mod=1,dmg_mod=1), Buff('Sickened',atk_mod=-2,dmg_mod=-2)] bulls_strength = Buff("Bull's Strength") bulls_strength.str_score = 4 cls.possible_buffs_list.append(bulls_strength) # Update UIC Model cls.uic._model = cls.c
def build_character(self): """Construct a character to play with""" ######## # BUILD HENRI ####### c = Character() c.base.str_score = 19 c.base.dex_score = 12 c.base.con_score = 13 c.base.cha_score = 14 c.BAB = 5 greatsword = Weapon("Greatsword", Attack(atk=+0, dmg_roll=DamageRoll.fromString("2d6"), crit_range=[19,20], crit_mult=2, two_handed=True)) c.equipment.main_hand = greatsword attacks = c.attacks self.c = c
if 'Character' not in locals().keys(): from model import (Character, RPGClass, Equipment, Weapon, Attack, Buff, Feat, auditable) class Ranger(RPGClass): def __init__(self): super(Ranger, self).__init__() self.hit_die = 10 self.fort = 5 # TODO: Scale will level self.ref = 5 self.will = 2 c = Character() c.name = 'Clement' c.lvl = 6 c.BAB = 6 c.rpg_class = Ranger() # Ability Scores c.base.str_score = 19 c.base.dex_score = 16 c.base.con_score = 14 # All the others are the default value of 10 # Armor breastplate = Equipment("Mithral Chain Shirt +2") breastplate.AC = 6 breastplate.ACP = 0 c.equipment.append(breastplate) cr = Equipment("Ammulute of Natural Armor +2")
if 'Character' not in locals().keys(): from model import (Character, RPGClass, Equipment, Weapon, Attack, Buff, Feat, auditable) class Cavalier(RPGClass): def __init__(self): super(Cavalier, self).__init__() self.hit_die = 10 self.fort = 7 # TODO: Scale will level self.ref = 3 self.will = 3 c = Character() c.name = 'Henri (Level 11)' c.lvl = 11 c.BAB = 11 c.rpg_class = Cavalier() # Ability Scores c.base.str_score = 20 c.base.dex_score = 12 c.base.con_score = 13 c.base.cha_score = 16 # All the others are the default value of 10 # Armor breastplate = Equipment("Mytheral Breastplate of Speed") breastplate.AC = 10 breastplate.ACP = -3 c.equipment.append(breastplate)