diff --git a/config/Makefile b/config/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..2926c4d624c515ddbf6b5bb02207a2cbb5f6b69a --- /dev/null +++ b/config/Makefile @@ -0,0 +1,12 @@ +filename=example +output: ${filename}.pdf + pdflatex ${filename}.tex +${filename}.pdf: + pdflatex ${filename}.tex +new: + if [ ! -d .git ] && [ -e ../.git ] + then + cp -n main.tex .gitignore .. + fi +clean: + rm -r *.{aux,toc,acn,acr,log,ptc,out,idx,ist,alg,glo} 2>/dev/null diff --git a/config/autocompile.sh b/config/autocompile.sh deleted file mode 100755 index cb580ace3d2ab7dfc8c492274b1adf99a7fc8c22..0000000000000000000000000000000000000000 --- a/config/autocompile.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash - -# if you're in the subtree, back up -[ ! -d .git ] && [ -e ../.git ] && \ - cd .. - -# If you're setting up: -[ ! -e main.tex ] && [ -e config/main.tex ] && \ - cp config/main.tex . && \ - ln -s config/autocompile.sh . && \ - ln -s config/latexmkrc . && \ - ln -s config/.gitignore . - -git gc --auto - -if [ $1 = clean ]; then - rm -r *aux *log main.{i,g}* *toc *.ptc *.out svg-inkscape 2>/dev/null - exit 0 -fi - -if [ $1 = tree ]; then - [ -e ../config ] || ( echo "You don't have a local config repo" && exit 1 ) - git status - git subtree -P config pull ../config master || exit 1 - git subtree -P config push ../config master || exit 1 -fi -pdflatex -shell-escape main.tex -makeglossaries main -makeindex main.idx -pdflatex main.tex diff --git a/config/bind.sty b/config/bind.sty index 3a61cb7158bc119e81532887a7f4d3ab70fe1560..62f9ae95dc5e615a2fa688bfe12db7bf439b6367 100644 --- a/config/bind.sty +++ b/config/bind.sty @@ -362,7 +362,7 @@ Roll & Result \\ } \newcommand{\randomtwoC}{ - \ifnum\value{r2c}>2% + \ifnum\value{r2c}>1% \setcounter{r2c}{1}\else% \addtocounter{r2c}{1}% \fi% @@ -403,7 +403,7 @@ Roll & Result \\ \ifnum\value{age}>0\addtocounter{r12}{\value{age}}\else\ifnum\value{r4}>0\addtocounter{r12}{\value{r4}}\else\addtocounter{r12}{3}\fi\fi% } -\newcommand{\mapentry}[1]{\addtocounter{list}{1}\subsubsection{\arabic{list}: #1}} +\newcommand{\mapentry}[1]{\needspace{2em}\addtocounter{list}{1}\subsubsection{\arabic{list}: #1}} \newcommand{\li}{\addtocounter{enc}{-1}\arabic{enc}&} \newcommand{\lii}{\addtocounter{list}{-1}\arabic{list}&} diff --git a/config/example.tex b/config/example.tex index 770db885adb973a66726aaf0ff04475bbf36f1e8..1f1ceb173a1a38f5168928e6ab72d09ade4d5a7d 100644 --- a/config/example.tex +++ b/config/example.tex @@ -96,6 +96,10 @@ With a little study, you can summon dozens of monsters, including {\tt\textbacks \gnome +\gnomishsoldier + +\gnomishsoldier + \gnomishillusionist \subsection{Gnolls} @@ -152,6 +156,8 @@ With a little study, you can summon dozens of monsters, including {\tt\textbacks \ogre +\deepogre + \subsection{Animals} \nurarat @@ -270,6 +276,10 @@ When using a bestiary chapter, the stats appear as dice rolls, rather than fixed \jelly +\jelly + +\jelly + \end{multicols} \section{Undead} diff --git a/config/monsters.sty b/config/monsters.sty index 7c8a8777f85cd594d8e896b159fe9dadf50f23c5..65900b77fe00d3e4f1d8d88bec1cff9747ab5edc 100644 --- a/config/monsters.sty +++ b/config/monsters.sty @@ -16,7 +16,7 @@ \newcommand{\lootMedium}{% \iftoggle{bestiarychapter}{% \ifodd\value{r2}$3D6$\else$2D6$\fi sp}{% -\setcounter{gold}{\thepage}\divide\value{gold} by \value{r4}% +\addtocounter{gold}{\thepage}\divide\value{gold} by \value{r4}% \ifnum\value{gold}<4% \setcounter{gold}{7}\fi% \arabic{gold} sp}% @@ -221,6 +221,12 @@ % ARMOUR +\newcommand{\partialelvish}{partial leather armour% + \ifnumcomp{\value{dr}}{>}{2}% + {\addtocounter{dr}{1}}% + {\divide\value{dr} by 2 \addtocounter{dr}{2}}% +} + \newcommand{\partialleather}{partial leather armour% \ifnumcomp{\value{dr}}{>}{3}% {\addtocounter{dr}{2}}% @@ -550,16 +556,17 @@ \ent{Abilities:} & #1 } - \newcommand{\claws}{ - Claws (+1 Damage) \addtocounter{str}{1} - } +\newcommand{\claws}{ + Claws (+1 Damage) \addtocounter{str}{1} + } -\newcommand{\quadraped}{ - Quadraped (double movement) +\newcommand{\quadraped}{% + Quadraped (double movement)% } - \newcommand{\teeth}{Teeth (+1 Damage after grapple) \addtocounter{str}{1} - } +\newcommand{\teeth}{% + Teeth (+1 Damage after grapple)\addtocounter{str}{1}% +} \newcommand{\web}{ \setcounter{track}{6}\addtocounter{track}{\value{str}} @@ -912,6 +919,7 @@ \randomtwo \addtocounter{enc}{-2} \randomtwoB + \randomthreeB \person{-2}% STRENGTH {\arabic{r2}}% DEXTERITY {\arabic{enc}}% SPEED @@ -924,10 +932,50 @@ \ifodd\value{page} \Path{Alchemy}{Illusion \arabic{r2}} \fi}% SKILLS -{\Dagger, \lootMedium}% EQUIPMENT +{\ifodd\value{r3}% + \Dagger, +\else% + \lootMedium% +\fi% +}% EQUIPMENT {\mana{2}} } +\newcommand{\gnomishsoldier}[1][\npc{\M}{Gnomish Soldier}]{ + #1 + \randomtwo + \addtocounter{enc}{-2} + \randomtwoB + \randomtwoC + \addtocounter{r2b}{-1} + \randomthree + \randomthreeB +\person{\arabic{enc}}% STRENGTH +{\arabic{r2}}% DEXTERITY +{\arabic{r2b}}% SPEED +{{\arabic{age}}% INTELLIGENCE +{\arabic{r2}}% WITS +{\arabic{r2b}}}% CHARISMA +{0}% DR +{\arabic{r2}}% COMBAT +{\ifnum\value{enc}<0% + Projectiles \arabic{r2c}, +\fi% +Academics 1, \ifodd\value{page} Crafts \arabic{r2}, \else \fi Deceit 1, \ifodd\value{page} \else Larceny \arabic{r2c}, \fi Stealth \arabic{r2c} +}% SKILLS +{\ifnum\value{enc}=0% + \shortsword +\else% + Shortbow, \Dagger% +\fi% +\ifnum\value{r3c}=2% + , \partialelvish% +\fi% +, \lootMedium +}% EQUIPMENT +{} +} + \newcommand{\gnomishillusionist}[1][\npc{\M}{Gnomish Illusionist}]{ #1 \randomtwo @@ -1416,6 +1464,7 @@ \addtocounter{r2b}{-2} \addtocounter{enc}{1} \randomdozen + \randomfourB \person{\arabic{r2b}}% STRENGTH {\arabic{r2}}% DEXTERITY {\arabic{enc}}% SPEED @@ -1427,7 +1476,19 @@ {Aggression 2, Projectiles \arabic{r2}, Athletics 1, Deceit 1, Stealth \arabic{r3}, \ifodd\value{r4}Tactics \arabic{r2}\fi% \ifodd\value{r3} \else\knacks{\perfectsneakattack}\fi% }% SKILLS -{\ifodd\value{r2}\woodaxe\else\javelin, dagger\fi}% EQUIPMENT +{\ifodd\value{r2}% + \woodaxe% +\else% + \ifodd\value{r12}% + \javelin, dagger% + \else% + \Dagger% + \fi% +\fi% +\ifnum\value{r4b}=4% + , lock picking set +\fi% +.}% EQUIPMENT {} } @@ -1556,7 +1617,7 @@ {} } -\newcommand{\ogre}[1][\npc{\T\N}{\arabic{r4b} Ogres}]{ +\newcommand{\ogre}[1][\npc{\T\N}{\addtocounter{r4b}{1}\arabic{r4b} Ogres}]{ #1 \randomthree\addtocounter{age}{3} \randomtwo\addtocounter{enc}{2} @@ -1584,6 +1645,35 @@ {} } +\newcommand{\deepogre}[1][\npc{\T\N}{\addtocounter{r4b}{1}\arabic{r4b} Ogres}]{ + #1 + \randomthree\addtocounter{age}{3} + \randomtwo\addtocounter{enc}{2} + \randomtwoB + \randomthreeC + \randomfourB +\person{\arabic{age}}% STRENGTH +{0}% DEXTERITY +{\arabic{enc}}% SPEED +{{-3}% INTELLIGENCE +{-1}% WITS +{-4}}% CHARISMA +{0}% DR +{\arabic{r2b}}% COMBAT +{\ifodd\value{r2c}% + Beast Ken +\else% + Vigilance +\fi\arabic{r2}}% SKILLS +{\ifodd\value{r3c} + Nothing. +\else + \greatclub +\fi +}% EQUIPMENT +{} +} + \newcommand{\undeadogre}[1][\npc{\D\N}{Undead Ogre}]{ #1 \randomtwo @@ -1752,6 +1842,7 @@ mana stone with \arabic{track} mana, \lootJewellery, \randomtwo\lootJewellery, \ #1 \randomfour \randomfour + \randomfour \addtocounter{track}{2} \setcounter{gold}{\value{r4}} \multiply\value{gold} by -1