Пример #1
0
class Dwarf(Race):
    name = "Dwarf"
    average_height = units.Feet(4)
    average_weight = units.Pound(120)
    average_lifespan = timedelta(days=36500)

    restriction_set = restrictions.RestrictionSet(
        ability_score=restrictions.AbilityScoreRestrictionSet(
            minimum_set=abilityscores.AbilityScoreSet(constitution=9),
            maximum_set=abilityscores.AbilityScoreSet(charisma=17),
        ),
        classes=restrictions.ClassRestrictionSet(included=(classes.Cleric,
                                                           classes.Fighter,
                                                           classes.Thief)),
        weapons=restrictions.WeaponRestrictionSet(excluded=(
            bflib.items.weapons.melee.swords.TwoHandedSword,
            bflib.items.weapons.melee.polearms.Polearm,
            bflib.items.weapons.ranged.bows.Longbow,
        )))
    racial_language = languages.Dwarvish
    special_ability_set = specialabilities.SpecialAbilitySet((
        specialabilities.Darkvision,
        specialabilities.DetectNewConstructions,
        specialabilities.DetectShiftingWalls,
        specialabilities.DetectSlantingPassages,
        specialabilities.DetectTraps,
    ))
    saving_throw_set = savingthrows.SavingThrowSet(death_poison=-4,
                                                   dragon_breath=-3,
                                                   paralysis_stone=-4,
                                                   spells=-4,
                                                   wands=-4)
Пример #2
0
class Halfling(Race):
    name = "Halfling"
    average_height = units.Feet(3)
    average_weight = units.Pound(60)
    average_lifespan = timedelta(days=109500)

    restriction_set = restrictions.RestrictionSet(
        ability_score=restrictions.AbilityScoreRestrictionSet(
            minimum_set=abilityscores.AbilityScoreSet(dexterity=9),
            maximum_set=abilityscores.AbilityScoreSet(strength=17),
        ),
        classes=restrictions.ClassRestrictionSet(included=(classes.Cleric,
                                                           classes.Fighter,
                                                           classes.Thief), ),
        hit_dice_max_size=restrictions.HitDiceMaxSizeRestriction(dice.D6),
        weapon_size=restrictions.WeaponSizeRestrictionSet(
            large=restrictions.WeaponSizeRestrictionSet.keywords.CannotWield,
            medium=restrictions.WeaponSizeRestrictionSet.keywords.
            NeedsTwoHands,
            small=restrictions.WeaponSizeRestrictionSet.keywords.CanWield,
        ))
    racial_language = languages.Halfling
    special_ability_set = specialabilities.SpecialAbilitySet(
        (specialabilities.HalflingHide, specialabilities.InitiativeBonus(1),
         specialabilities.MeleeDefenseBonus(2),
         specialabilities.RangedWeaponAccuracyBonus(1)))
    saving_throw_set = savingthrows.SavingThrowSet(death_poison=-4,
                                                   dragon_breath=-3,
                                                   paralysis_stone=-4,
                                                   spells=-4,
                                                   wands=-4)
Пример #3
0
class Gnoll(Race):
    name = "Gnoll"
    average_height = units.Feet(7)
    average_weight = units.Pound(300)
    average_lifespan = timedelta(days=27375)

    racial_class = racialclass.Gnoll
    restriction_set = restrictions.RestrictionSet(
        ability_score=restrictions.AbilityScoreRestrictionSet(
            minimum_set=abilityscores.AbilityScoreSet(strength=13,
                                                      constitution=11),
            maximum_set=abilityscores.AbilityScoreSet(charisma=15,
                                                      intelligence=15),
        ),
        classes=restrictions.ClassRestrictionSet(included=(classes.Cleric,
                                                           classes.Fighter,
                                                           classes.MagicUser)),
    )
    racial_language = languages.Bugbear
    special_ability_set = specialabilities.SpecialAbilitySet((
        specialabilities.Darkvision,
        specialabilities.PowerfulScent,
    ))
    saving_throw_set = savingthrows.SavingThrowSet(
        death_poison=-4,
        paralysis_stone=-4,
    )
Пример #4
0
class Race(object):
    __metaclass__ = abc.ABCMeta

    name = ""
    average_height = units.Feet(0)
    average_weight = units.Pound(0)
    average_lifespan = timedelta(0)

    restriction_set = restrictions.RestrictionSet()
    racial_language = languages.Common
    special_ability_set = specialabilities.SpecialAbilitySet()
    saving_throw_set = savingthrows.SavingThrowSet()
Пример #5
0
class Human(Race):
    name = "Human"
    average_height = units.Feet(6)
    average_weight = units.Pound(175)
    average_lifespan = timedelta(days=27375)

    restriction_set = restrictions.RestrictionSet(
        classes=restrictions.ClassRestrictionSet()
    )
    racial_language = languages.Common
    special_ability_set = specialabilities.SpecialAbilitySet((
        specialabilities.ExperienceBonus(10)
    ))
    saving_throw_set = savingthrows.SavingThrowSet()
Пример #6
0
class Elf(Race):
    name = "Elf"
    average_height = units.Feet(5)
    average_weight = units.Pound(130)
    average_lifespan = timedelta(days=438000)

    restriction_set = restrictions.RestrictionSet(
        ability_score=restrictions.AbilityScoreRestrictionSet(
            minimum_set=abilityscores.AbilityScoreSet(intelligence=9),
            maximum_set=abilityscores.AbilityScoreSet(constitution=17),
        ),
        classes=restrictions.ClassRestrictionSet(access_combined=True),
        hit_dice_max_size=restrictions.HitDiceMaxSizeRestriction(dice.D6))
    racial_language = languages.Elvish
    special_ability_set = specialabilities.SpecialAbilitySet(
        (specialabilities.Darkvision, specialabilities.DetectSecretDoor,
         specialabilities.GhoulParalysisImmunity,
         specialabilities.SurpriseResistance))
    saving_throw_set = savingthrows.SavingThrowSet(paralysis_stone=1,
                                                   spells=2,
                                                   wands=2)
Пример #7
0
class Race(object):
    __metaclass__ = abc.ABCMeta

    name = ""
    average_height = units.Feet(0)
    average_weight = units.Pound(0)
    average_lifespan = timedelta(0)

    restriction_set = restrictions.RestrictionSet()
    racial_class = None
    racial_language = languages.Common
    size = None
    special_ability_set = specialabilities.SpecialAbilitySet()
    saving_throw_set = savingthrows.SavingThrowSet()

    wear_locations = (
        WearLocation.Head,
        WearLocation.Face,
        WearLocation.Neck,
        WearLocation.Torso,
        WearLocation.Arms,
        WearLocation.Arms,
        WearLocation.Hands,
        WearLocation.Hands,
        WearLocation.Rings,
        WearLocation.Rings,
        WearLocation.Legs,
        WearLocation.Legs,
        WearLocation.Feet,
        WearLocation.Feet,
        WearLocation.Bandolier,
        WearLocation.Back,
        WearLocation.Belt,
        WearLocation.Waist,
    )

    wield_locations = (
        WieldLocation.LeftHand,
        WieldLocation.RightHand,
    )