Skip to content
Snippets Groups Projects
Unverified Commit 1e24a63c authored by Malin Freeborn's avatar Malin Freeborn
Browse files

make dlist environment

parent 7c0f110f
No related branches found
No related tags found
No related merge requests found
......@@ -122,6 +122,17 @@ Then we have \verb"\begin{exampletext}" for example:
\end{boxtext}
\subsubsection{Showing Dice}
You can show dice with \verb"\dicef{7}", which shows up as `\dicef{7}'.
And you can list dice, with results, with the `\texttt{dlist}' environment.
\begin{dlist}
\item Badger
\item Fox
\item Gazebo
\end{dlist}
\subsection{Magic}
\subsubsection{Magical Items}
......
......@@ -322,6 +322,24 @@ bookmarks=true]%
\label{#2}
}
\newcommand\dicef[1]{%
\setcounter{track}{#1}%
\ifnum\value{track}>0%
\whileboolexpr{%
test {\ifnumcomp{\value{track}}{>}{6}}%
}{%
\addtocounter{track}{-5}%
\epsdice{5}%
}%
\epsdice{\value{track}}
\else%
\arabic{track}%
\fi%
}
\newenvironment{dlist}%
{\begin{list}{\Large\dicef{\value{list}}}{\usecounter{list}}}%
{\end{list}}%
\newcounter{blingNo}
\setcounter{blingNo}{0}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment