first pass at druid shapes to monster blocks

This commit is contained in:
matsavage
2021-05-04 23:08:32 +01:00
parent 406b4d004d
commit a097e55fbd
2 changed files with 85 additions and 56 deletions
+85 -54
View File
@@ -1,64 +1,95 @@
\twocolumn[
\begin{@twocolumnfalse}
% \maketitle
\section*{Known Beasts}
[% for shape in character.all_wild_shapes|sort(attribute="name") %]%
[[ shape.name ]][% if not loop.last %], [% endif %]%
[% endfor %]%
\vspace{3ex}
\end{@twocolumnfalse}
]
\newpage
\section*{Known Beasts}
[% for shape in character.all_wild_shapes|sort(attribute='challenge_rating') %]
[% if not character.can_assume_shape(shape) %]
{\color{mygrey}
[% else %]
{
[% endif %]
[% if use_dnd_decorations %]
[% for shape in character.all_wild_shapes|sort(attribute='challenge_rating') %]
\begin{DndMonster}{[[ shape.name ]]}
\DndMonsterType{[[ shape.description ]]}
% If you want to use commas in the key values, enclose the values in braces.
\DndMonsterBasics[
armor-class = {[[ shape.armor_class ]]},
hit-points = {[[ shape.hp_max ]] ([[ shape.hit_dice ]])},
speed = {[[ shape.speed ]] ft.[% if shape.swim_speed %], [[ shape.swim_speed ]]ft. swim[% endif %][% if shape.fly_speed %], [[ shape.fly_speed ]] ft. fly[% endif %]},
]
\DndMonsterAbilityScores[
str = [[ shape.strength.value ]],
dex = [[ shape.dexterity.value ]],
con = [[ shape.constitution.value ]],
int = [[ character.intelligence.value ]],
wis = [[ character.wisdom.value ]],
cha = [[ character.charisma.value ]],
]
\section*{[[ shape.name ]]}
[% if shape.description %]
\subsection*{[[ shape.description ]]}
[% endif %]
\DndMonsterDetails[
%saving-throws = {Str +0, Dex +0, Con +0, Int +0, Wis +0, Cha +0},
%skills = {Acrobatics +0, Animal Handling +0, Arcana +0, Athletics +0, Deception +0, History +0, Insight +0, Intimidation +0, Investigation +0, Medicine +0, Nature +0, Perception +0, Performance +0, Persuasion +0, Religion +0, Sleight of Hand +0, Stealth +0, Survival +0},
%damage-vulnerabilities = {cold},
%damage-resistances = {bludgeoning, piercing, and slashing from nonmagical attacks},
%damage-immunities = {poison},
%condition-immunities = {poisoned},
senses = {[[ shape.senses ]]},
languages = {[[ shape.languages ]]},
%challenge = 1,
]
%\DndMonsterSection{Actions}
[[ shape.__doc__ | rst_to_latex(top_heading_level=2) ]]
\end{DndMonster}
[% endfor %]
[% else %]
[% for shape in character.all_wild_shapes|sort(attribute='challenge_rating') %]
[% if not character.can_assume_shape(shape) %]
{\color{mygrey}
[% else %]
{
[% endif %]
\begin{tabular}{c | c | c}
Armor Class & Hit Points & Speed \\
\hline
[[ shape.armor_class ]] &
[[ shape.hp_max ]] ([[ shape.hit_dice ]]) &
[[ shape.speed ]] \\
[% if shape.swim_speed %]
& & [[ shape.swim_speed ]] swim \\
[% endif %]
[% if shape.fly_speed %]
& & [[ shape.fly_speed ]] fly \\
[% endif %]
\end{tabular}
\section*{[[ shape.name ]]}
[% if shape.description %]
\subsection*{[[ shape.description ]]}
[% endif %]
\vspace{0.2cm}
\begin{tabular}{c | c | c}
Armor Class & Hit Points & Speed \\
\hline
[[ shape.armor_class ]] &
[[ shape.hp_max ]] ([[ shape.hit_dice ]]) &
[[ shape.speed ]] \\
[% if shape.swim_speed %]
& & [[ shape.swim_speed ]] swim \\
[% endif %]
[% if shape.fly_speed %]
& & [[ shape.fly_speed ]] fly \\
[% endif %]
\end{tabular}
\begin{tabular}{c | c | c}
STR & DEX & CON \\
\hline
[[ shape.strength.value ]] ([[ shape.strength.modifier|mod_str ]]) &
[[ shape.dexterity.value ]] ([[ shape.dexterity.modifier|mod_str ]]) &
[[ shape.constitution.value ]] ([[ shape.constitution.modifier|mod_str ]]) \\
\end{tabular}
\vspace{0.2cm}
\vspace{0.2cm}
\begin{tabular}{c | c | c}
STR & DEX & CON \\
\hline
[[ shape.strength.value ]] ([[ shape.strength.modifier|mod_str ]]) &
[[ shape.dexterity.value ]] ([[ shape.dexterity.modifier|mod_str ]]) &
[[ shape.constitution.value ]] ([[ shape.constitution.modifier|mod_str ]]) \\
\end{tabular}
\begin{tabular}{p{0.1\textwidth} p{0.32\textwidth}}
\textbf{Skills:} & [[ shape.skills ]] \\
\textbf{Senses:} & [[ shape.senses ]] \\
\textbf{Languages:} & [[ shape.languages ]] \\
\textbf{Resistance:} & [[ shape.damage_resistance ]] \\
\textbf{Immunities:} & [[ shape.condition_immunities ]] \\
\end{tabular}
\vspace{0.2cm}
\vspace{0.2cm}
\begin{tabular}{p{0.1\textwidth} p{0.32\textwidth}}
\textbf{Skills:} & [[ shape.skills ]] \\
\textbf{Senses:} & [[ shape.senses ]] \\
\textbf{Languages:} & [[ shape.languages ]] \\
\textbf{Resistance:} & [[ shape.damage_resistance ]] \\
\textbf{Immunities:} & [[ shape.condition_immunities ]] \\
\end{tabular}
[[ shape.__doc__ | rst_to_latex(top_heading_level=2) ]]
\vspace{0.2cm}
} %\color
[% endfor %]
[[ shape.__doc__ | rst_to_latex(top_heading_level=2) ]]
} %\color
[% endfor %]
[% endif %]
-2
View File
@@ -220,8 +220,6 @@ def make_sheet(
if character.is_spellcaster:
tex.append(create_spellbook_tex(character, use_dnd_decorations=fancy_decorations))
if len(character.spells) > 0:
tex.append(create_spellbook_tex(character, use_dnd_decorations=fancy_decorations))
# Create a list of Artificer infusions
infusions = getattr(character, "infusions", [])
if len(infusions) > 0: