DnD_5e.character_classes.druid module
- class DnD_5e.character_classes.druid.Druid(**kwargs)[source]
Bases:
SpellCaster,CharacterDruid character class
- current_eq(other) bool[source]
Check to see if self is identical to other by looking at everything in equals as well as the following attributes: wild shape slots, wild shapes, current shape
- get_current_shape() Creature | None[source]
- Returns:
current shape (or None if in original shape)
- Return type:
Creature (or None)
- get_ac() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
armor class
- Return type:
positive integer
- get_hit_dice() Tuple[int, int][source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
hit dice
- Return type:
TYPE_DICE_TUPLE
- get_max_hp() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
max hit points
- Return type:
positive integer
- get_temp_hp() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
temporary hit points
- Return type:
non-negative integer
- get_current_hp() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
current hit points
- Return type:
non-negative integer
- is_bloodied() bool[source]
Tell whether self is bloodied (current hit points at or below half of maximum). If a wild shape is active, use the statistics of the wild shape.
- Returns:
True if self is bloodied, False otherwise
- Return type:
- is_hp_max() bool[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
True if current hp equals max hp, False otherwise
- Return type:
- get_speed() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
speed
- Return type:
positive integer
- get_vision() str[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
vision
- Return type:
one of these strings: “normal”, “darkvision”, “blindsight”, “truesight”
- get_ability(ability: str) int[source]
If a wild shape is active, use the statistics of the wild shape
- Parameters:
ability (one of these strings: "strength", "dexterity", "constitution", "intelligence", "wisdom", "charisma") – the name of an ability score
- Returns:
the ability score modifier
- Return type:
- Raise:
ValueError if ability is not valid
- get_strength() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
strength modifier
- Return type:
- get_dexterity() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
dexterity modifier
- Return type:
- get_constitution() int[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
constitution modifier
- Return type:
- get_proficiencies() set[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
proficiencies
- Return type:
set of strings
- get_vulnerabilities() set[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
vulnerabilities
- Return type:
set of strings
- get_resistances() set[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
resistances
- Return type:
set of strings
- get_immunities() set[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
immunities
- Return type:
set of strings
- get_saving_throw(ability: str) int[source]
Get the modifier for an ability saving throw. Note: this does NOT roll the saving throw. If a wild shape is active, use the statistics of the wild shape.
- Parameters:
ability (one of these strings: "strength", "dexterity", "constitution", "intelligence", "wisdom", "charisma') – an ability score name
- Returns:
the modifier for an ability saving throw
- Return type:
- Raise:
ValueError if ability is not valid
- get_attacks() list[source]
If a wild shape is active, use the statistics of the wild shape
- Returns:
attacks
- Return type:
list of Attacks
- add_wild_shape(beast: Creature)[source]
Add a wild shape
- Parameters:
beast (Creature) – the wild shape to add
- Returns:
None
- can_cast(spell)[source]
Determine if self can cast the given Spell. Note: does not check spell slots.
- Parameters:
spell (py:class:Spell) – the Spell self is trying to cast
- Returns:
True if self can cast spell, False otherwise
- Return type:
- take_damage(damage, damage_type=None, is_critical: bool = False)[source]
Take damage, applying vulnerabilities, resistances, and immunities as necessary. If self has a wild shape active, that beast takes damage first. If the beast reaches 0 hit points, the wild shape ends and self goes back to their original form and takes the rest of the damage.