adds a graph for SAL, lots of goblinomancy and honestly it's scaring me a little

This commit is contained in:
Vicky 2024-06-03 21:01:40 +02:00 committed by Dandaedre
parent 15232f585b
commit ea1ee91450
6 changed files with 469 additions and 4 deletions

View File

@ -1,6 +1,49 @@
\section{Specialiste de Armes Lourdes}
Excelle à infliger de lourds dégâts et à incapaciter ses cibles. Le spécialiste des Armes Lourdes souffre d’importants problèmes de manœuvrabilité et de défense, qu’il compense par ses grandes Capacités de Contrôle.\\
\section{Spécialiste des Armes Lourdes}
Excelle à infliger de lourds dégâts et à neutraliser ses cibles. Le spécialiste des Armes Lourdes souffre d’importants problèmes de manœuvrabilité et de défense, qu’il compense par ses grandes Capacités de Contrôle.\\
Mécanique exclusive : \mecanique{Delicate destruction}.
\begin{wrapfigure}{R}{0.25\textwidth}
\begin{asy}
settings.outformat="pdf";
size(200);
real[] data={
3.006912442,
3.977338421,
0.2530541012,
0.001,
5,
2.696019019,
1.916932907,
};
pen op=opacity(0.8);
pen[] Pens={
op+rgb(0.467, 0.455, 0.231),
op+rgb(0.682, 0.365, 0.251),
op+rgb(0.702, 0.647, 0.333),
op+rgb(0.549, 0.671, 0.631),
op+rgb(0.82, 0.694, 0.529),
op+rgb(0.341, 0.282, 0.322),
op+rgb(0.549, 0.671, 0.631),
};
string[] Legend={
"Support",
"Dégats",
"Survivabilité",
"Mobilité",
"C.C.",
"Altérations",
"QoL",
};
RadarPlot rp=RadarPlot(data,Legend,Pens,maxY=5,Step=1);
rp.draw();
\end{asy}
\end{wrapfigure}
\input{Tables/SpecialisteArmesLourdes-data.tex}

99
Misc/Radar.tex Normal file
View File

@ -0,0 +1,99 @@
\begin{asydef}
struct RadarPlot{
real[] data;
string[] Legend;
pen[] Pens;
pen gridPen;
pen axisPen;
pen labelPen;
pen legendPen;
int n,m;
real pieAngle;
int maxX;
int maxY;
real step;
real Step;
pair O=(0,0);
void drawSectors(){
guide g;
for(int i=0;i<n;++i){
g=arc(0,data[i],i*pieAngle,(i+1)*pieAngle);
fill(O--g--cycle,Pens[i%m]);
}
}
void drawGrid(){
for(int i=1;i<=(int)(maxY/step);++i){
draw(circle(O,i*step),gridPen);
}
for(int i=0;i<maxX;++i){
draw(rotate(i*360/maxX)*(O--(maxY,0)),gridPen);
}
}
void drawLabels(){
for(int i=1;i<=(int)(maxY/Step);++i){
draw(Label(string(i*Step),(i*Step,0)),roundbox,filltype=UnFill,labelPen);
}
}
void drawLegend(){
transform t;
real a;
pair v;
for(int i=0;i<n;++i){
a=(i-1.25)*pieAngle;
t=rotate(a+90);
v=t*(5,0);
if(a<90 || a>270){
label(rotate(-90)*t*Legend[i],v,unit(v),legendPen);
}else{
label(rotate(a-180)*Legend[i],v,unit(v),legendPen);
}
}
}
void draw(){
drawGrid();
drawSectors();
drawLabels();
drawLegend();
}
void putText(string s, real x, real y, pair pos=O, pen p=currentpen){
label(s,rotate(x*pieAngle)*(y,0),pos,p);
}
void operator init(real[] data, string[] Legend, pen[] Pens
,int maxX=2data.length
,int maxY=(int)max(data)+1
,pen gridPen=rgb(0.912,0.9,0.876)
,pen axisPen=black
,pen labelPen=black
,pen legendPen=black
,real step=1
,real Step=2step
){
this.data=copy(data);
this.Pens=copy(Pens);
this.Legend=copy(Legend);
this.n=data.length;
this.m=Pens.length;
this.pieAngle=360/n;
this.maxX=maxX;
this.maxY=maxY;
this.gridPen=gridPen;
this.axisPen=axisPen;
this.labelPen=labelPen;
this.legendPen=legendPen;
this.step=step;
this.Step=Step;
}
};
\end{asydef}

View File

@ -25,9 +25,11 @@
\usepackage{tabularray} % Greatest tables so far
\usepackage{tkz-graph} % Great tkz graphs !
\usepackage[inline]{asymptote} % /!\ Hazardous ! Adds the radar package. Very cursed.
% How our graphics behave
\epstopdfDeclareGraphicsRule{.pdf}{png}{.png}{convert #1 \OutputFile}
\DeclareGraphicsExtensions{.png,.pdf}
%\epstopdfDeclareGraphicsRule{.pdf}{png}{.png}{convert #1 \OutputFile}
%\DeclareGraphicsExtensions{.png,.pdf}
% How our glossaries behave
\usepackage[nopostdot, style=super, nonumberlist, toc]{glossaries}
@ -65,3 +67,6 @@
\usepackage{lmodern} % Changes font for a microtype font
\usepackage{microtype} % Adds microtype features (reduces overflow by 50%)
\usepackage{hyperref} % Adds the \nameref command % Best practice says: load last
% Radar
\input{Misc/Radar.tex}

149
Ravenous-1.asy Normal file
View File

@ -0,0 +1,149 @@
if(!settings.multipleView) settings.batchView=false;
settings.tex="pdflatex";
settings.inlinetex=true;
deletepreamble();
defaultfilename="Ravenous-1";
if(settings.render < 0) settings.render=4;
settings.outformat="";
settings.inlineimage=true;
settings.embed=true;
settings.toolbar=false;
viewportmargin=(2,2);
struct RadarPlot{
real[] data;
string[] Legend;
pen[] Pens;
pen gridPen;
pen axisPen;
pen labelPen;
pen legendPen;
int n,m;
real pieAngle;
int maxX;
int maxY;
real step;
real Step;
pair O=(0,0);
void drawSectors(){
guide g;
for(int i=0;i<n;++i){
g=arc(0,data[i],i*pieAngle,(i+1)*pieAngle);
fill(O--g--cycle,Pens[i%m]);
}
}
void drawGrid(){
for(int i=1;i<=(int)(maxY/step);++i){
draw(circle(O,i*step),gridPen);
}
for(int i=0;i<maxX;++i){
draw(rotate(i*360/maxX)*(O--(maxY,0)),gridPen);
}
}
void drawLabels(){
for(int i=1;i<=(int)(maxY/Step);++i){
draw(Label(string(i*Step),(i*Step,0)),roundbox,filltype=UnFill,labelPen);
}
}
void drawLegend(){
transform t;
real a;
pair v;
for(int i=0;i<n;++i){
a=(i-1.25)*pieAngle;
t=rotate(a+90);
v=t*(5,0);
if(a<90 || a>270){
label(rotate(-90)*t*Legend[i],v,unit(v),legendPen);
}else{
label(rotate(a-180)*Legend[i],v,unit(v),legendPen);
}
}
}
void draw(){
drawGrid();
drawSectors();
drawLabels();
drawLegend();
}
void putText(string s, real x, real y, pair pos=O, pen p=currentpen){
label(s,rotate(x*pieAngle)*(y,0),pos,p);
}
void operator init(real[] data, string[] Legend, pen[] Pens
,int maxX=2data.length
,int maxY=(int)max(data)+1
,pen gridPen=rgb(0.912,0.9,0.876)
,pen axisPen=black
,pen labelPen=black
,pen legendPen=black
,real step=1
,real Step=2step
){
this.data=copy(data);
this.Pens=copy(Pens);
this.Legend=copy(Legend);
this.n=data.length;
this.m=Pens.length;
this.pieAngle=360/n;
this.maxX=maxX;
this.maxY=maxY;
this.gridPen=gridPen;
this.axisPen=axisPen;
this.labelPen=labelPen;
this.legendPen=legendPen;
this.step=step;
this.Step=Step;
}
};
settings.outformat="pdf";
size(200);
real[] data={
3.006912442,
3.977338421,
0.2530541012,
0.001,
5,
2.696019019,
1.916932907,
};
pen op=opacity(0.8);
pen[] Pens={
op+rgb(0.467, 0.455, 0.231),
op+rgb(0.682, 0.365, 0.251),
op+rgb(0.702, 0.647, 0.333),
op+rgb(0.549, 0.671, 0.631),
op+rgb(0.82, 0.694, 0.529),
op+rgb(0.341, 0.282, 0.322),
op+rgb(0.549, 0.671, 0.631),
};
string[] Legend={
"Support",
"Dégats",
"Survivabilité",
"Mobilité",
"C.C.",
"Altérations",
"QoL",
};
RadarPlot rp=RadarPlot(data,Legend,Pens,maxY=5,Step=1);
rp.draw();

164
Ravenous-1.tex Normal file
View File

@ -0,0 +1,164 @@
\setlength{\unitlength}{1pt}%
\makeatletter%
\let\ASYencoding\f@encoding%
\let\ASYfamily\f@family%
\let\ASYseries\f@series%
\let\ASYshape\f@shape%
\makeatother%
{\catcode`"=12%
\includegraphics{\ASYprefix\jobname-1_0}%
}%
\special{pdf:q}%
\begin{picture}( 194.458657, 200.750000)%
\special{pdf:\ASYraw{
-181.097917 16.902583 m
-10.555587 16.902583 l
-10.555587 183.272899 l
-181.097917 183.272899 l
-181.097917 16.902583 l
h
-19.899612 97.393217 m
-19.899612 102.782265 l
-19.899612 104.247591 -18.711731 105.435472 -17.246405 105.435472 c
-13.708795 105.435472 l
-12.243469 105.435472 -11.055587 104.247591 -11.055587 102.782265 c
-11.055587 97.393217 l
-11.055587 95.927891 -12.243469 94.740010 -13.708795 94.740010 c
-17.246405 94.740010 l
-18.711731 94.740010 -19.899612 95.927891 -19.899612 97.393217 c
h
W* n
}%
}%
\special{pdf:q}%
\special{pdf:\ASYraw{
-181.097917 16.902583 m
-14.727600 16.902583 l
-14.727600 183.272899 l
-181.097917 183.272899 l
-181.097917 16.902583 l
h
-36.386644 97.393217 m
-36.386644 102.782265 l
-36.386644 104.247591 -35.198763 105.435472 -33.733437 105.435472 c
-30.195827 105.435472 l
-28.730501 105.435472 -27.542619 104.247591 -27.542619 102.782265 c
-27.542619 97.393217 l
-27.542619 95.927891 -28.730501 94.740010 -30.195827 94.740010 c
-33.733437 94.740010 l
-35.198763 94.740010 -36.386644 95.927891 -36.386644 97.393217 c
h
W* n
}%
}%
\special{pdf:q}%
\special{pdf:\ASYraw{
-181.097917 16.902583 m
-14.727600 16.902583 l
-14.727600 183.272899 l
-181.097917 183.272899 l
-181.097917 16.902583 l
h
-52.873676 97.393217 m
-52.873676 102.782265 l
-52.873676 104.247591 -51.685794 105.435472 -50.220468 105.435472 c
-46.682858 105.435472 l
-45.217532 105.435472 -44.029651 104.247591 -44.029651 102.782265 c
-44.029651 97.393217 l
-44.029651 95.927891 -45.217532 94.740010 -46.682858 94.740010 c
-50.220468 94.740010 l
-51.685794 94.740010 -52.873676 95.927891 -52.873676 97.393217 c
h
W* n
}%
}%
\special{pdf:q}%
\special{pdf:\ASYraw{
-181.097917 16.902583 m
-14.727600 16.902583 l
-14.727600 183.272899 l
-181.097917 183.272899 l
-181.097917 16.902583 l
h
-69.360707 97.393217 m
-69.360707 102.782265 l
-69.360707 104.247591 -68.172826 105.435472 -66.707500 105.435472 c
-63.169890 105.435472 l
-61.704564 105.435472 -60.516683 104.247591 -60.516683 102.782265 c
-60.516683 97.393217 l
-60.516683 95.927891 -61.704564 94.740010 -63.169890 94.740010 c
-66.707500 94.740010 l
-68.172826 94.740010 -69.360707 95.927891 -69.360707 97.393217 c
h
W* n
}%
}%
\special{pdf:q}%
\special{pdf:\ASYraw{
-181.097917 16.902583 m
-14.727600 16.902583 l
-14.727600 183.272899 l
-181.097917 183.272899 l
-181.097917 16.902583 l
h
-85.847739 97.393217 m
-85.847739 102.782265 l
-85.847739 104.247591 -84.659858 105.435472 -83.194532 105.435472 c
-79.656922 105.435472 l
-78.191596 105.435472 -77.003714 104.247591 -77.003714 102.782265 c
-77.003714 97.393217 l
-77.003714 95.927891 -78.191596 94.740010 -79.656922 94.740010 c
-83.194532 94.740010 l
-84.659858 94.740010 -85.847739 95.927891 -85.847739 97.393217 c
h
W* n
}%
}%
\special{pdf:Q}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\usefont{\ASYencoding}{\ASYfamily}{\ASYseries}{\ASYshape}%
\ASYalign(-81.731073,100.463070)(-0.500000,-0.500000){1}%
\special{pdf:Q}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\usefont{\ASYencoding}{\ASYfamily}{\ASYseries}{\ASYshape}%
\ASYalign(-65.182215,100.463070)(-0.500000,-0.500000){2}%
\special{pdf:Q}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\usefont{\ASYencoding}{\ASYfamily}{\ASYseries}{\ASYshape}%
\ASYalign(-48.633357,100.463070)(-0.500000,-0.500000){3}%
\special{pdf:Q}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\usefont{\ASYencoding}{\ASYfamily}{\ASYseries}{\ASYshape}%
\ASYalign(-32.084499,100.463070)(-0.500000,-0.500000){4}%
\end{picture}%
\kern -194.458657pt%
\special{pdf:Q}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\usefont{\ASYencoding}{\ASYfamily}{\ASYseries}{\ASYshape}%
\ASYalign(-15.535641,100.463070)(-0.500000,-0.500000){5}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-20.486414,137.926454)(-0.500000,0.221517){0.433884 -0.900969 0.900969 0.433884}{Support}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-79.066519,184.642529)(-0.500000,0.218749){0.974928 -0.222521 0.222521 0.974928}{Dégats}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-152.114716,167.969754)(-0.500000,0.000000){0.781831 0.623490 -0.623490 0.781831}{Survivabilité}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-184.624222,100.463070)(-0.500000,-1.000000){0.000000 -1.000000 1.000000 0.000000}{Mobilité}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-152.114716,32.956386)(-0.500000,-1.000000){0.781831 -0.623490 0.623490 0.781831}{C.C.}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-79.066519,16.283611)(-0.500000,-1.000000){0.974928 0.222521 -0.222521 0.974928}{Altérations}%
\special{pdf:0.000000 g}%
\fontsize{12.000000}{14.400000}\selectfont%
\ASYalignT(-20.486414,62.999686)(-0.500000,-0.778483){0.433884 0.900969 -0.900969 0.433884}{QoL}%

5
latexmkrc Normal file
View File

@ -0,0 +1,5 @@
sub asy {return system("asy -o '$_[0]' '$_[0]'");}
add_cus_dep("asy","eps",0,"asy");
add_cus_dep("asy","pdf",0,"asy");
add_cus_dep("asy","tex",0,"asy");
push @generated_exts, "pre", "%R-[0-9]*.pdf", "%R-[0-9]*.prc", "%R-[0-9]*.tex", "%R-[0-9]*.out", "%R-[0-9]*.pbsdat", "%R.pbsdat", "%R-[0-9]*.eps", "%R-*.asy"