diff --git a/config/bind.sty b/config/bind.sty index 0cab9e727c5e27972cfb9ea982b82d2b4d28b560..c494329f36a950785f936cd9d813b4a1fce3c999 100644 --- a/config/bind.sty +++ b/config/bind.sty @@ -1,3 +1,4 @@ \RequirePackage{config/layout} +\RequirePackage{config/loot} \RequirePackage{config/stats} \RequirePackage{config/monsters} diff --git a/config/docs.tex b/config/docs.tex index 51f728182afa40a98a2b5c2336fbd9dc5f5e90f8..42b065ec24cc18681215a09c15a4d8650fc5b317 100644 --- a/config/docs.tex +++ b/config/docs.tex @@ -1,5 +1,6 @@ \documentclass[a4paper,openany]{book} \usepackage{layout} +\usepackage{loot} \usepackage{stats} \usepackage{monsters} \usepackage{lipsum} diff --git a/config/layout.sty b/config/layout.sty index dca0d56712681ac227d04fb2bd8bcfd465191172..4816b6b4417d5c91b3f9e4ee3e495f07917cec69 100644 --- a/config/layout.sty +++ b/config/layout.sty @@ -574,12 +574,27 @@ interior code={ \path[tcb fill interior] ([xshift=-2mm]interior.west) \raggedbottom \newcommand{\currentsphere}{magic} -\newcommand{\sphere}[1]{\setcounter{spelllevel}{0}\renewcommand{\currentsphere}{#1}\index{#1}\section{\currentsphere}} -\newcommand{\spelllevel}{\addtocounter{spelllevel}{1}% - \subsection{\currentsphere~ Level \arabic{spelllevel}}} -\newcommand{\enhancement}[3]{\paragraph[(#1) #2: #3]{(#1) Enhancement -- #2:}\index{Enhancement!#2}} -\newcommand{\magicitem}[7]{\vspace{2em}\needspace{4em}\noindent\textbf{#1} -\index{Magical Item!#1} + +\newcommand{\sphere}[1]{% + \setcounter{spelllevel}{0}% + \renewcommand{\currentsphere}{#1}% + \index{#1}% + \section{\currentsphere} +}% + +\newcommand{\spelllevel}{% + \addtocounter{spelllevel}{1}% + \subsection{\currentsphere~ Level \arabic{spelllevel}}% +} + +\newcommand{\enhancement}[3]{% + \paragraph[(#1) #2: #3]{(#1) Enhancement -- #2:}% + \index{Enhancement!#2}% +} + +\newcommand{\magicitem}[7]{% + \vspace{2em}\needspace{4em}\noindent\textbf{#1}% + \index{Magical Item!#1} \noindent \textit{Spells: #2, }% @@ -592,18 +607,21 @@ interior code={ \path[tcb fill interior] ([xshift=-2mm]interior.west) \needspace{2em}% } -\newcommand{\manalake}[8]{\subsection{#1 (Level #8)} +\newcommand{\manalake}[8]{ + \subsection{#1 (Level #8)} \textit{Spells: #2, }\textit{Path: #3, }\textit{Duration: #4, }\textit{Type: #5, }\textit{Potence: #6, }\textit{#7 MP}% Type can be 'pocket spell', 'magical item', or 'artefact'. \index{Mana Lakes!#1} \vspace{.3em} } -\newcommand{\spell}[4]{\subsubsection[#1: #4]{#1} +\newcommand{\spell}[4]{ + \subsubsection[#1: #4]{#1} -{\it Type: #2, Skill: #3} + {\it Type: #2, Skill: #3} -\noindent} + \noindent% +} % Toggles for knacks @@ -800,7 +818,8 @@ Roll & Result \\ \newcommand{\sqName}{} -\newcommand{\sidequest}[1]{\renewcommand{\sqName}{#1} +\newcommand{\sidequest}[1]{% + \renewcommand{\sqName}{#1} \resumecontents[\sqarea] \subsection{\sqName} \stopcontents[\sqarea] @@ -822,10 +841,10 @@ Roll & Result \\ } - \newcommand{\shortline}{\line(1,0){22}} - \newcommand{\weeline}{\line(1,0){30} \hspace{.6cm}} - \newcommand{\vlongline}{\line(1,0){100}\hspace{0.8cm}} - \newcommand{\writeline}{\line(1,0){59}} +\newcommand{\shortline}{\line(1,0){22}} +\newcommand{\weeline}{\line(1,0){30} \hspace{.6cm}} +\newcommand{\vlongline}{\line(1,0){100}\hspace{0.8cm}} +\newcommand{\writeline}{\line(1,0){59}} \newcommand{\fiveboxes}{\ding{111}\ding{111}\ding{111}\ding{111}\ding{111}} \newcommand{\threeboxes}{\ding{111}\ding{111}\ding{111}} \newcommand{\threecircles}{\ding{109}\ding{109}\ding{109}} diff --git a/config/loot.sty b/config/loot.sty new file mode 100644 index 0000000000000000000000000000000000000000..9748722faaeef01dea8405b01838639e9d44ab6e --- /dev/null +++ b/config/loot.sty @@ -0,0 +1,79 @@ +\ProvidesPackage{config/stats} +%%%%%%%%%%%%%%%%%%%% LOOT %%%%%%%%%%%%%%%%%%%% + +\newcommand{\lootSmall}{% + \iftoggle{bestiarychapter}{% + \ifodd\value{r2}% + $3D6$\else$2D6$% + \fi cp}{ + \randomdozen\arabic{r12} cp}% +} + +\newcommand{\lootMedium}{% + \iftoggle{bestiarychapter}{% + \ifodd\value{r2}% + $3D6$% + \else% + $2D6$% + \fi~sp}{% + \addtocounter{gold}{\thepage}% + \divide\value{gold} by \value{r4}% + \ifnum\value{gold}<4% + \setcounter{gold}{7}% + \fi% + \arabic{gold}~sp}% +} + +\newcommand{\lootBig}{% +\iftoggle{bestiarychapter}{% + \ifodd\thepage $3D6-2$\else$2D6+4$\fi gp}{% + \randomdozen\addtocounter{r12}{8}\arabic{r12}gp% + }% +} + +\newcommand{\lootMagic}{% + \iftoggle{team}{Mana stone holding 2 MP}% + {\iftoggle{bestiarychapter}{}% + {\ifnumcomp{\value{r2}}{>}{1}% + {\ifodd\value{r3}% + \ifodd\value{r4}% + \ifodd\value{r3b}% + Sorcerer's Eye% + \else% + Deck of Cards\fi\else Wild Seeds\fi\else\ifodd\value{r2b}Bag of Holding% + \else% + Defensive Heart% + \fi% + \fi}% + {\ifodd\value{r3}% + \ifodd\value{r4}% + Portal Scroll% + \else% + Sleeping Dust% + \fi% + \else% + \ifodd\value{r2b}% + \ifnum\value{dr}>0% + Ring of Asphyxiation% + \else + Ghost Shield% + \fi% + \else% + Bag of Tricks% + \fi% + \fi}% +}}} + +\newcommand{\lootJewellery}{% +\iftoggle{bestiarychapter}{jewellery worth \ifodd\value{r2}$3D6$sp\else$1D6+2$gp\fi}% + {\ifnumcomp{\value{r2}}{>}{1}{\ifodd\value{r3}% + \ifodd\value{r4}% + golden necklace worth \arabic{r12}~sp\else% + golden ring worth \thechapter~sp\fi\else% + jewel encrusted dagger worth \thepage~sp\fi}% + {\ifodd\value{r3}% + \ifodd\value{r4}% + ornate silver earrings worth 1 gp\else + gem encrusted broach worth \thechapter gp\fi\else% + \randomthreeB saphire pendant worth \arabic{r3b}gp\fi}}} + diff --git a/config/monsters.sty b/config/monsters.sty index 134f4a03edd178fb4fd886102a191b68d07ebfc6..66266c745560d32c99e32663f255989ecefab305 100644 --- a/config/monsters.sty +++ b/config/monsters.sty @@ -5,6 +5,9 @@ % |_| |_| |_|\___/|_| |_|___/\__\___|_| |___/ % +% This is a list of monster-commands. You put in the command, like "\dragon", and a dragon will be conjured unto your pdf. +% If you're unhapy with your dragon, copy-paste the bit where it says \dragon{blah}{bla}, then change those numbers. + \newcommand{\auroch}[1][\npc{\A\T}{\arabic{page} Aurochs}]{ #1 \animal{2}% STRENGTH @@ -13,7 +16,7 @@ {1}% WITS {2}% DR {1}% AGGRESSION -{Athletics 1}% SKILLS +{Athletics~1}% SKILLS {Stampede}% ABILITIES {\addtocounter{xpbonus}{-4}} } @@ -85,7 +88,7 @@ {2}% WITS {0}% DEXTERITY {2}% AGGRESSION -{Athletics \arabic{enc}, Survival \arabic{r2}\knacks{\charge}}% SKILLS +{Athletics~\arabic{enc}, Survival~\arabic{r2}\knacks{\charge}}% SKILLS {Flight}% ABILITIES {} } @@ -101,7 +104,7 @@ {0}% WITS {2}% DR {2}% AGGRESSION -{Stealth \arabic{enc}, Tactics \arabic{r2b}, \knacks{\firststrike , \adrenalinesurge , \perfectsneakattack}}% SKILLS +{Stealth~\arabic{enc}, Tactics~\arabic{r2b}, \knacks{\firststrike , \adrenalinesurge , \perfectsneakattack}}% SKILLS {None}% ABILITIES {} } @@ -116,7 +119,7 @@ {1}% WITS {1}% DR {\arabic{r2}}% AGGRESSION -{Athletics 2, Survival \arabic{enc}, Tactics 2}% SKILLS +{Athletics~2, Survival~\arabic{enc}, Tactics~2}% SKILLS {\teeth, \quadraped}% ABILITIES {} } @@ -611,7 +614,7 @@ Academics~1, \ifodd\value{page} Crafts~\arabic{r2}, \else \fi Deceit~1, \ifodd\v {\spear}% \fi% \fi, % - \partialplate% + \partialplate, % \ifodd\value{r4} \shield, \fi @@ -1320,7 +1323,7 @@ mana stone holding \arabic{track} MP, \ifodd\thechapter\lootJewellery\fi}% EQUIP {-5}}% CHARISMA {2}% DR {\arabic{r3b}}% COMBAT -{Aggression 2, \ifodd\thechapter Projectiles \arabic{r3}, \fi Academics 3, \ifodd\value{gold}Crafts \arabic{r3}, \fi Deceit \arabic{r2b}, Medicine \arabic{r2b}, Vigilance \arabic{r3b} +{Aggression 2, \ifodd\thechapter Projectiles~\arabic{r3}, \fi Academics~3, \ifodd\value{gold}Crafts~\arabic{r3}, \fi Deceit~\arabic{r2b}, Medicine~\arabic{r2b}, Vigilance~\arabic{r3b} \Path{Alchemy \& Devotion (Qualm\"e)}{\ifodd\value{page}\aldaron \else \conjuration \arabic{age}, \fate \fi~\arabic{r3}, \enchantment \arabic{r4}, \ifodd\thechapter \invocation \arabic{r2b}, \fi \necromancy 5}}% SKILLS {\ifnum\value{r3b}>2% \longsword% @@ -1353,7 +1356,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r3}}% WITS {\arabic{track}}% DR {\arabic{r4}}% AGGRESSION -{\ifnum\value{gold}>0 Athletics \arabic{gold}, Stealth \arabic{gold}\else Projectiles \arabic{r3}\fi, \knacks{\ifnum\value{r4}>3\disarm, \fi \unstoppable}}% SKILLS +{\ifnum\value{gold}>0 Athletics \arabic{gold}, Stealth~\arabic{gold}\else Projectiles~\arabic{r3}\fi, \knacks{\ifnum\value{r4}>3\disarm, \fi \unstoppable}}% SKILLS {Acidic damage, gelatinous (DR does not apply to fire-based attacks)}% ABILITIES {} } @@ -1370,7 +1373,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r2}}% WITS {\arabic{enc}}% DR {2}% AGGRESSION -{Stealth \arabic{r2}, Survival \arabic{r3}, Vigilance \arabic{r2b}}% SKILLS +{Stealth~\arabic{r2}, Survival~\arabic{r3}, Vigilance~\arabic{r2b}}% SKILLS {}% ABILITIES {} } @@ -1385,7 +1388,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r2}}% WITS {1}% DR {\ifodd\value{r2}1\fi}% AGGRESSION -{Athletics 2, Survival 1}% SKILLS +{Athletics~2, Survival~1}% SKILLS {\quadraped}% ABILITIES {} } @@ -1402,7 +1405,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r2}}% WITS {1}% DR {\ifodd\value{r2}1\else 2\fi}% AGGRESSION -{Athletics 2, Survival 1, Vigilance 1}% SKILLS +{Athletics~2, Survival~1, Vigilance~1}% SKILLS {\quadraped}% ABILITIES {} } @@ -1418,7 +1421,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {1}% WITS {1}% DR {1}% AGGRESSION -{Athletics 2, Survival 1}% SKILLS +{Athletics~2, Survival~1}% SKILLS {\quadraped}% ABILITIES {} } @@ -1434,7 +1437,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {3}% WITS {0}% DR {\arabic{r2}}% AGGRESSION -{Survival 2, Vigilance 2}% SKILLS +{Survival~2, Vigilance~2}% SKILLS {\quadraped}% ABILITIES {}% } @@ -1450,7 +1453,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {1}% WITS {0}% DR {\arabic{r2}}% AGGRESSION -{Survival 2, Vigilance 2}% SKILLS +{Survival~2, Vigilance~2}% SKILLS {\teeth, \quadraped}% ABILITIES {}% } @@ -1471,8 +1474,11 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r3}}}% CHARISMA {\arabic{age}}% DR {\arabic{r2}}% AGGRESSION -{Academics \arabic{r3}, Ether Lore \arabic{r2}, Stealth 3, Vigilance \arabic{r2}}% SKILLS -{\ifnumcomp{\value{r12}}{=}{12}{Pet rock}{None}}% EQUIPMENT +{Academics~\arabic{r3}, Ether~Lore~\arabic{r2}, Stealth~3, Vigilance~\arabic{r2}}% SKILLS +{\ifnumcomp{\value{r12}}{=}{12}% + {Pet rock}% + {None} +\perfectArmour}% EQUIPMENT {} } @@ -1493,9 +1499,9 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ {\arabic{r2b}}}% CHARISMA {\arabic{age}}% DR {\arabic{r4}}% AGGRESSION -{Crafts \arabic{r2}, Deceit \arabic{r3}, Ether Lore 1, }% SKILLS +{Crafts~\arabic{r2}, Deceit~\arabic{r3}, Ether Lore~1, }% SKILLS {\ifodd\value{r3}None\else\greatsword\fi}% EQUIPMENT -{} +{\perfectArmour} } \newcommand{\archmage}[1][\npc{\E}{Archmage}]{ diff --git a/config/stats.sty b/config/stats.sty index b2b85d104400f11657f43bca09fb80a140c84602..84f3a5eb1e6ad6b5cde5c40e3700453a0a88e43f 100644 --- a/config/stats.sty +++ b/config/stats.sty @@ -1,91 +1,52 @@ \ProvidesPackage{config/stats} %%%%%%%%%%%%%%%%%%%% Introduction -% This is a list of monster-commands. You put in the command, like "\dragon", and a dragon will be conjured unto your pdf. -% If you're unhapy with your dragon, copy-paste the bit where it says \dragon{blah}{bla}, then change those numbers. -%%%%%%%%%%%%%%%%%%%% LOOT %%%%%%%%%%%%%%%%%%%% \newtoggle{bestiarychapter} \settoggle{bestiarychapter}{false} -\newcommand{\lootSmall}{% -\iftoggle{bestiarychapter}{% -\ifodd\value{r2}$3D6$\else$2D6$\fi cp}{ -\randomdozen\arabic{r12} cp}% -} - -\newcommand{\lootMedium}{% -\iftoggle{bestiarychapter}{% -\ifodd\value{r2}$3D6$\else$2D6$\fi~sp}{% -\addtocounter{gold}{\thepage}\divide\value{gold} by \value{r4}% -\ifnum\value{gold}<4% - \setcounter{gold}{7}\fi% -\arabic{gold}~sp}% -} - -\newcommand{\lootBig}{% -\iftoggle{bestiarychapter}{% -\ifodd\thepage $3D6-2$\else$2D6+4$\fi gp}{% -\randomdozen\addtocounter{r12}{8}\arabic{r12}gp}% -} - -\newcommand{\lootMagic}{% - \iftoggle{team}{Mana stone holding 2 MP}% - {\iftoggle{bestiarychapter}{}% - {\ifnumcomp{\value{r2}}{>}{1}% - {\ifodd\value{r3}% - \ifodd\value{r4}% - \ifodd\value{r3b}% - Sorcerer's Eye% - \else% - Deck of Cards\fi\else Wild Seeds\fi\else\ifodd\value{r2b}Bag of Holding% - \else% - Defensive Heart% - \fi% - \fi}% - {\ifodd\value{r3}% - \ifodd\value{r4}% - Portal Scroll% - \else% - Sleeping Dust% - \fi% - \else% - \ifodd\value{r2b}% - \ifnum\value{dr}>0% - Ring of Asphyxiation% - \else - Ghost Shield% - \fi% - \else% - Bag of Tricks% - \fi% - \fi}% -}}} - -\newcommand{\lootJewellery}{% -\iftoggle{bestiarychapter}{jewellery worth \ifodd\value{r2}$3D6$sp\else$1D6+2$gp\fi}% - {\ifnumcomp{\value{r2}}{>}{1}{\ifodd\value{r3}% - \ifodd\value{r4}% - golden necklace worth \arabic{r12}~sp\else% - golden ring worth \thechapter~sp\fi\else% - jewel encrusted dagger worth \thepage~sp\fi}% - {\ifodd\value{r3}% - \ifodd\value{r4}% - ornate silver earrings worth 1 gp\else - gem encrusted broach worth \thechapter gp\fi\else% - \randomthreeB saphire pendant worth \arabic{r3b}gp\fi}}} -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% _ -% _ __ ___ ___ _ __ ___| |_ ___ _ __ -%| '_ ` _ \ / _ \| '_ \/ __| __/ _ \ '__| -%| | | | | | (_) | | | \__ \ || __/ | -%|_| |_| |_|\___/|_| |_|___/\__\___|_| -% -% _ _ -% ___| |_ __ _| |_ ___ -%/ __| __/ _` | __/ __| -%\__ \ || (_| | |_\__ \ -%|___/\__\__,_|\__|___/ +% _ _ +% ___| |_ __ _| |_ +% / __| __/ _` | __| +% \__ \ || (_| | |_ +% |___/\__\__,_|\__| +% +% +% _ _ _ +% | |__ | | ___ ___| | _____ +% | '_ \| |/ _ \ / __| |/ / __| +% | |_) | | (_) | (__| <\__ \ +% |_.__/|_|\___/ \___|_|\_\___/ +% % +% This file makes stat blocks for monsters. +% +% The writer feeds in something like this: +% +% \npc{\M}{Patrick the Pyromanacer} +% +% \person{0}% STRENGTH +% {0}% DEXTERITY +% {0}% SPEED +% {{0}% INTELLIGENCE +% {0}% WITS +% {0}}% CHARISMA +% {0}% DR +% {0}% COMBAT +% {}% SKILLS +% {Nothing}% EQUIPMENT +% {} +% +% The \person command takes various stats, and +% inside that 'SKILLS' variable (variable no. 8), +% we can add additional things, like +% \knacks{\firststrike}, or +% \Path{Blood}{\invocation{2}}, which gives your +% wizzard 'invocation 2'. +% +% Most of the rest of the commands deal with +% properly calculating derived stats, like the TN +% to hit the creature. + \newtoggle{mind} \newtoggle{examplecharacter} @@ -100,15 +61,24 @@ \newcommand{\weaponknackone}{} \newcommand{\weaponknacktwo}{} +% we calculate damage here because we can't display 1d6+6 damage - it has to turn into 2d6+2 damage. \newcommand{\calculatedamage}[1]{% - \setcounter{damagebonus}{#1}% - \setcounter{numberofdice}{1}% -\whileboolexpr{ - test {\ifnumcomp{\value{damagebonus}}{>}{3}} + \setcounter{damagebonus}{#1}% + \setcounter{numberofdice}{1}% + \whileboolexpr{test {\ifnumcomp{\value{damagebonus}}{>}{3}}}{% + \addtocounter{damagebonus}% + {-4}\addtocounter{numberofdice}{1}% }% - {\addtocounter{damagebonus}{-4}\addtocounter{numberofdice}{1}}% - {$\arabic{numberofdice}D6\ifnumcomp{\value{damagebonus}}{>}{0}{+\arabic{damagebonus}$}{\ifnumcomp{\value{damagebonus}}{<}{0}{\arabic{damagebonus}$}{$}}}% - } + {$\arabic{numberofdice}D6% + \ifnumcomp{\value{damagebonus}}{>}{0}% + {+\arabic{damagebonus}$}% + {% + \ifnumcomp{\value{damagebonus}}{<}{0}{% + \arabic{damagebonus}$}% + {$}% + }% + }% +} %%%%%%%%%%%%%%%%%%%% Character Generation %%%%%%%%%%%%%%%%%%%% @@ -229,6 +199,10 @@ % ARMOUR +%% For perfect armour, stick \perfectArmour in the additional notes category of a \person (#9). + +\newcommand{\perfectArmour}{\gdef\armourtype{(Perfect)}} + \newcommand{\partialelvish}{partial leather armour% \ifnumcomp{\value{dr}}{>}{2}% {\addtocounter{dr}{1}}% @@ -296,77 +270,89 @@ %%%%%%%%%%% Person % -\newcommand{\person}[9]{\settoggle{mind}{true} -\setcounter{str}{#1} -\setcounter{dex}{#2} -\setcounter{spd}{#3} -\mind#4 -\setcounter{dr}{#5} -\setcounter{att}{#6} -\renewcommand{\skills}{#7} -\renewcommand{\equipment}{#8} -\renewcommand{\mods}{#9} +\newcommand{\person}[9]{ + \settoggle{mind}{true} + \setcounter{str}{#1} + \setcounter{dex}{#2} + \setcounter{spd}{#3} + \mind#4 + \setcounter{dr}{#5} + \setcounter{att}{#6} + \renewcommand{\skills}{#7} + \renewcommand{\equipment}{#8} + \renewcommand{\mods}{#9} -\clean + \clean -\renewcommand{\armourtype}{P} -\gdef\armourtype{P} + \renewcommand{\armourtype}{P} + \gdef\armourtype{P} -\begin{tcolorbox}[title={\name}, before upper={\parindent0pt}, halign=flush left, left=2mm, watermark text=\npcsymbol] + \begin{tcolorbox}[title={\name}, + before upper={\parindent0pt}, + halign=flush left, + left=10pt, + right=15pt, + watermark text=\npcsymbol] -\iftoggle{personality}{ + \iftoggle{personality}{ -\textbf{Archetype:} \archetype + \textbf{Archetype:} \archetype -\textbf{Personality:} \personality + \textbf{Personality:} \personality -\textbf{Mannerism:} \mannerism + \textbf{Mannerism:} \mannerism -\vspace{1em} + \vspace{1em} -\settoggle{personality}{false}}% -{} -\creaturestats + \settoggle{personality}{false}}% + {} + \creaturestats -\derivedstats -\end{tcolorbox} - \settoggle{debug}{false} - \settoggle{examplecharacter}{false} + \derivedstats + \end{tcolorbox} + \settoggle{debug}{false} + \settoggle{examplecharacter}{false} } -\newcommand{\animal}[9]{\settoggle{mind}{false} -\setcounter{str}{#1} -\setcounter{dex}{#2} -\setcounter{spd}{#3} -\setcounter{wts}{#4} -\setcounter{dr}{#5} -\setcounter{att}{#6} -\renewcommand{\skills}{#7} -\renewcommand{\abilities}{#8} -\renewcommand{\mods}{#9} +\newcommand{\animal}[9]{ + \settoggle{mind}{false} + \setcounter{str}{#1} + \setcounter{dex}{#2} + \setcounter{spd}{#3} + \setcounter{wts}{#4} + \setcounter{dr}{#5} + \setcounter{att}{#6} + \renewcommand{\skills}{#7} + \renewcommand{\abilities}{#8} + \renewcommand{\mods}{#9} -\clean + \clean -\renewcommand{\armourtype}{C} + \renewcommand{\armourtype}{C} -\begin{tcolorbox}[title={\name},before upper={\parindent0pt},watermark text=\npcsymbol] + \begin{tcolorbox}[title={\name}, + before upper={\parindent0pt}, + halign=flush left, + left=10pt, + right=15pt, + watermark text=\npcsymbol] -\iftoggle{personality}{ + \iftoggle{personality}{ -\textbf{Personality:} \personality + \textbf{Personality:} \personality -\textbf{Mannerism:} \mannerism + \textbf{Mannerism:} \mannerism -\vspace{1em} + \vspace{1em} -\settoggle{personality}{false}}% -{} -\creaturestats + \settoggle{personality}{false}}% + {} + \creaturestats -\derivedstats + \derivedstats -\end{tcolorbox} + \end{tcolorbox} } @@ -483,9 +469,16 @@ \noindent Attack \arabic{att}\ifnumcomp{\value{att}}{=}{\value{attb}}{}{ (\arabic{attb})}, Initiative \arabic{spd}\ifnumcomp{\value{spd}}{=}{\value{spdb}}{}{ (\arabic{spdb})}, Damage \calculatedamage{\value{str}}\ifnumcomp{\value{str}}{=}{\value{strb}}{}{ (\calculatedamage{\value{strb}})}, - \iftoggle{examplecharacter}{\mbox{Defence \arabic{dex},} }{ + \iftoggle{examplecharacter}{\mbox{Defence \arabic{dex},} }{% TN \arabic{dex}% - \ifnumcomp{\value{dr}}{>}{0}{\ifnum\pdfstrcmp{\armourtype}{P}=0\addtocounter{dexb}{3} (\arabic{dexb})\fi\ifnum\pdfstrcmp{\armourtype}{C}=0\addtocounter{dexb}{5} (\arabic{dexb})\fi}{}, + \ifnumcomp{\value{dr}}{>}{0}{ + \ifnum\pdfstrcmp{\armourtype}{P}=0% + \addtocounter{dexb}{3} (\arabic{dexb})% + \fi + \ifnum\pdfstrcmp{\armourtype}{C}=0% + \addtocounter{dexb}{5}~(\arabic{dexb})% + \fi% + }{}, }% \ifnumcomp{\value{dr}}{>}{0}{DR \arabic{dr}~\armourtype, }{}% \ifnum\value{mp}>0% @@ -530,7 +523,7 @@ %% / \| __/ %% /_/\_\_| %% - \newcommand{\calculateXP}{ +\newcommand{\calculateXP}{% %% Sanitize: init+5, dam+5, \addtocounter{spdb}{5} \addtocounter{strb}{5} @@ -586,7 +579,7 @@ \vspace{.1cm} - } +} % %%%%%%%%%%%%%%%%%%%% Creature Abilities diff --git a/config/test.tex b/config/test.tex index 5cadcf7cc4cc8cd6cf627d76a87dbb81b67790dd..27f3a94cf12ab0660573af7fed61b912932570ac 100644 --- a/config/test.tex +++ b/config/test.tex @@ -1,5 +1,6 @@ \documentclass[a4paper,openany]{book} \usepackage{layout} +\usepackage{loot} \usepackage{stats} \usepackage{monsters} \usepackage{lipsum}