From 6d28c37b4731c8c778b85c0024c86c5f41e6ed3e Mon Sep 17 00:00:00 2001
From: Malin Freeborn <malinfreeborn@posteo.net>
Date: Sun, 17 Mar 2024 06:20:13 +0100
Subject: [PATCH] make jellies a swarm

---
 monsters.sty | 72 ++++++++++++++++++++++++----------------------------
 stats.sty    | 14 +++++++---
 2 files changed, 43 insertions(+), 43 deletions(-)

diff --git a/monsters.sty b/monsters.sty
index 6f0e1d2c..94866884 100644
--- a/monsters.sty
+++ b/monsters.sty
@@ -1868,47 +1868,36 @@
   }
 }
 
-\newcommand{\jelly}[1][\npc{\A}{\ifnum\value{r4}>3 Black\else \ifnum\value{r4}>2 Red \else \ifnum\value{r4}>1 Brown\else Transluscent\fi\fi\fi~ Ooze}]{
-  \randomfour
-  \randomfourB
-  \addtocounter{track}{2}
-  \setcounter{gold}{\value{r4}}
-  \multiply\value{gold} by -1
-  \addtocounter{gold}{3}
-  \randomthree
-  \randomthreeB
-  #1
-\animal{\arabic{r4}}% STRENGTH
-{\arabic{gold}}% DEXTERITY 
-{\arabic{gold}}% SPEED
-{\arabic{r3}}% WITS
-{\arabic{track}}% DR
-{0}% AGGRESSION
-{}% SKILLS
-{
-  \acidBody%
-  \ifnum\value{gold}<1
-    , \acidSpray%
+\newcommand\jelly{%
+  \randomtwoC%
+  \randomthree%
+  \randomfour%
+  \randomdozen%
+  \setcounter{enc}{\value{r12}}%
+    \addtocounter{enc}{\value{r4}}%
+  \setcounter{att}{\value{r4}}%
+    \addtocounter{att}{\value{r2}}%
+  \setcounter{Speed}{3}%
+    \addtocounter{Speed}{-\value{r4}}%
+  \setcounter{Wits}{2}%
+    \addtocounter{Wits}{-\value{r4}}%
+  \swarm[\gloopy, %
+  \ifnum\value{r4}=3%
+    \acidSpray%
+  \fi]{\ifcase\value{r4}\relax\or%
+    Transluscent %
+  \or%
+    Red%
+  \or%
+    Brown%
   \else%
-   , \gloopy%
-  \fi%
-  \ifnum\value{gold}<0%
-    , \gelRegen\addtocounter{xpbonus}{1}%
+    Black%
   \fi%
-}% ABILITIES
-{
-  \setcounter{Brawl}{\value{r4b}}
-  \setcounter{Athletics}{\value{gold}}
-  \setcounter{Stealth}{\value{gold}}
-  \ifnum\value{gold}<0
-    \setcounter{Projectiles}{\value{r3}}
-  \fi
-  \knacks{\ifnum\value{r4}>3
-    \berserker,
-  \fi
-  \unstoppable
-  }
-}
+  \space Ooze}% Name
+  {\value{enc}}% HP
+  {\value{att}}% Attack
+  {\value{Speed}}% Speed
+  {\value{Wits}}% Wits
 }
 
 \newcommand{\umberhulk}[1][\npc{\A}{Umber Hulk}]{
@@ -2137,6 +2126,11 @@
 %%%%% Swarms %%%%%
 
 \newcommand\basiliskSwarm{
+  \ifnum\value{diceNo}>\value{r4}
+    \setcounter{diceNo}{\value{r4}}
+  \else
+    \stepcounter{diceNo}
+  \fi
   \randomdozen
   \swarm{Basilisk Hatchlings}% Name
   {\arabic{r12}}%
diff --git a/stats.sty b/stats.sty
index 68c8fcc1..a9dd0f5b 100644
--- a/stats.sty
+++ b/stats.sty
@@ -860,10 +860,11 @@
 
     \normalfont
     \ifdefempty{\abilities}{}{%
-      \textbf{Abilities}: \abilities
-      \vspace{1em}
+      \textbf{Abilities:} \abilities
     }%
+    \vspace{2em}
     \end{tcolorbox}%
+    \null
   }
 
 
@@ -910,16 +911,21 @@
 }
 
 \newcommand{\gelRegen}{%
-  Regeneration (1 HP/ round, max. \setcounter{hp}{\value{Strength}}\addtocounter{hp}{6}\roundUp{hp} \arabic{hp})%
+  \setcounter{diceNo}{\value{hp}}\divide\value{diceNo} by 2%
+  Regeneration (1 \glsentrytext{hp}/ round, max. \arabic{diceNo})%
 }
 
-\newcommand\gloopy{%
+\newcommand\viscid{%
   Viscid (on a tie, the attacker \emph{must} inflict Damage, but the weapon sticks into the body,
   \setcounter{track}{\value{Strength}}%
   \addtocounter{track}{7}%
   \tn[\arabic{track}] to pull out)%
 }
 
+\newcommand\gloopy{%
+  Liquid (non-fire Damage removes 2~\glsfmtplural{hp} but creates a 1~\glsentrytext{hp} copy)%
+}
+
 \newcommand{\amphibious}{
 	Amphibious%
 }
-- 
GitLab