From ba99bde7f38ed75370de755ff077fa1149365d43 Mon Sep 17 00:00:00 2001 From: Malin Freeborn <malinfreeborn@posteo.net> Date: Sun, 24 Mar 2024 09:44:17 +0100 Subject: [PATCH] initial experiments --- arms.sty | 15 ++++++++------- main.tex | 35 ++++++++++++++++++++++++++++++++++- stats.sty | 13 +++++++++---- 3 files changed, 51 insertions(+), 12 deletions(-) diff --git a/arms.sty b/arms.sty index 8c744735..5e5c13fc 100644 --- a/arms.sty +++ b/arms.sty @@ -14,13 +14,14 @@ % The Weight Rating = ( Att + Dam ) - 3 \newcounter{weaponBonus} +\newcounter{weaponDamage} \newcounter{covering} \newcounter{armourDR} \newcommand\weapon[4][]{% \setcounter{weaponBonus}{#3}% - \setcounter{damage}{#4}% + \setcounter{weaponDamage}{#4}% \setcounter{heft}{#4}% \setcounter{weight}{#4}% \ifnum#3>-1% If the weapon's attack bonus is positive, @@ -41,7 +42,7 @@ %% It remains unterminated so you can add Costs. \newcommand\showWeapon[1]{% - #1 & \arabic{weaponBonus} & \arabic{damage} & \arabic{heft} & \arabic{weight} + #1 & \arabic{weaponBonus} & \arabic{weaponDamage} & \arabic{heft} & \arabic{weight} } \newcommand\rangedWeapon[4][0]{% @@ -104,18 +105,18 @@ \newcommand{\boulder}{\weapon[\addtocounter{weight}{3}]{Boulder}{-3}{5}} \newcommand{\chair}{\weapon[\addtocounter{weaponBonus}{-1}]{Chair}{2}{1}} -\newcommand{\club}{\weapon[\addtocounter{damage}{-1}]{Club}{1}{1}} -\newcommand{\cudgel}{\weapon[\addtocounter{damage}{-1}]{Cudgel}{0}{0}} +\newcommand{\club}{\weapon[\addtocounter{weaponDamage}{-1}]{Club}{1}{1}} +\newcommand{\cudgel}{\weapon[\addtocounter{weaponDamage}{-1}]{Cudgel}{0}{0}} \newcommand{\Dagger}{\weapon{Dagger}{0}{2}} \newcommand{\firepoker}{\weapon{Firepoker}{1}{0}} \newcommand{\flail}{\weapon{Flail}{0}{3}} \newcommand{\giantsword}{\weapon{Giant Sword}{4}{3}} \newcommand{\greataxe}{\weapon{Great Axe}{2}{3}} \newcommand{\greatsword}{\weapon{Greatsword}{3}{3}} -\newcommand{\greatclub}{\weapon[\addtocounter{damage}{-1}]{Great Club}{3}{4}} +\newcommand{\greatclub}{\weapon[\addtocounter{weaponDamage}{-1}]{Great Club}{3}{4}} \newcommand{\javelin}{\weapon{Javelin}{2}{1}} \newcommand{\knife}{\weapon{Knife}{0}{1}} -\newcommand{\Log}{\weapon[\addtocounter{damage}{-3}]{Log}{1}{0}} +\newcommand{\Log}{\weapon[\addtocounter{weaponDamage}{-3}]{Log}{1}{0}} \newcommand{\rapier}{\weapon[\addtocounter{weight}{-1}]{Rapier}{1}{1}} \newcommand{\largerock}{\weapon[\addtocounter{weight}{3}]{Rock (large)}{-1}{2}} \newcommand{\longsword}{\weapon{Longsword}{2}{2}} @@ -130,7 +131,7 @@ \newcommand{\glaive}{\weapon{Glaive}{3}{2}} \newcommand{\stick}{\weapon{Stick}{1}{0}} \newcommand{\walkingStick}{\weapon{Walking stick}{1}{0}} -\newcommand{\whip}{\weapon[\addtocounter{damage}{-1}\addtocounter{heft}{1}]{Whip}{2}{0}} +\newcommand{\whip}{\weapon[\addtocounter{weaponDamage}{-1}\addtocounter{heft}{1}]{Whip}{2}{0}} \newcommand{\warhammer}{\weapon{Warhammer}{1}{4}} \newcommand{\woodaxe}{\weapon[\addtocounter{heft}{1}]{Wood Axe}{1}{2}} diff --git a/main.tex b/main.tex index 7089bafc..973c9137 100644 --- a/main.tex +++ b/main.tex @@ -13,6 +13,39 @@ \chapter{Stuff} -test +\begin{multicols}{2} + +\goblin + +\elf + +\humanthief + +\humanthief + +\newcommand\statblock[4]{ + \clean + \setcounter{Strength}{#1} + \setcounter{Dexterity}{#2} + \setcounter{Speed}{#3} + \mind#4 + + %%%%%%%%%% + \textbf{\name} + \foreach\Att in {Strength,Dexterity,Speed}% + {\Att: \arabic{\Att}\quad} + + \hrulefill + + \foreach\Att in {Intelligence,Wits,Charisma}% + {\Att: \arabic{\Att}\quad} +} + +\npc{\M\Hu}{Bob} +\statblock{1}{2}{3}% + {{-3}{-2}{-1}} + + +\end{multicols} \end{document} diff --git a/stats.sty b/stats.sty index 0aa55483..41db93c3 100644 --- a/stats.sty +++ b/stats.sty @@ -463,10 +463,10 @@ \creaturestats - \skillsEtc - \computeStats + \skillsEtc + \derivedstats \end{tcolorbox} @@ -558,8 +558,8 @@ #9 - \skillsEtc% \computeStats + \skillsEtc% \derivedstats% \end{tcolorbox}% }{ @@ -598,6 +598,7 @@ \setcounter{weight}{0} \setcounter{encumbrance}{0} \setcounter{damage}{0} + \setcounter{weaponDamage}{0} \setcounter{knacks}{0} \setcounter{mp}{0} \setcounter{xpbonus}{0} @@ -708,6 +709,9 @@ \setcounter{ap}{\value{Speed}}% \addtocounter{ap}{3}% \addtocounter{ap}{-\value{encumbrance}}% + \foreach \k in {\showKnacks}{ + X + } } %% _ _ _ @@ -735,8 +739,9 @@ \iftoggle{allyCharacter}{$2D6$\ifnum\value{att}>-1 +\fi}{}% \arabic{att}% \setcounter{enc}{\value{att}},% + \setcounter{damage}{4}% \addtocounter{damage}{\value{Strength}} - \addtocounter{damage}{4}% + \addtocounter{damage}{\value{weaponDamage}} \mbox{Dam \dmg{damage}, }% \ifnumcomp{\value{dr}}{>}{0}{% \setcounter{enc}{\value{att}}% -- GitLab