This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
\label{function_8c}\index{function.c@{function.c}}
|
||||
{\ttfamily \#include "{}../include/function.\+h"{}}\newline
|
||||
{\ttfamily \#include "{}../include/display.\+h"{}}\newline
|
||||
{\ttfamily \#include "{}../include/read.\+h"{}}\newline
|
||||
{\ttfamily \#include $<$SDL2/\+SDL\+\_\+events.\+h$>$}\newline
|
||||
{\ttfamily \#include $<$SDL2/\+SDL\+\_\+image.\+h$>$}\newline
|
||||
{\ttfamily \#include $<$SDL2/\+SDL\+\_\+keycode.\+h$>$}\newline
|
||||
@@ -24,10 +25,14 @@ void \textbf{ free2D} (char $\ast$$\ast$tab, int x)
|
||||
\begin{DoxyCompactList}\small\item\em Cette fontion permet de liberer l\textquotesingle{}espace tu tableau 2D de char. \end{DoxyCompactList}\item
|
||||
char \textbf{ can\+IGo\+Direction} (char value\+Of\+NCase, char value\+Of\+NPlus\+One\+Case)
|
||||
\begin{DoxyCompactList}\small\item\em La fontction permet de savoir si le joueur peut ce deplacer dans une direction. \end{DoxyCompactList}\item
|
||||
void \textbf{ move} (char $\ast$$\ast$tab, \textbf{ vect} $\ast$player\+Pos, \textbf{ vect} direction, \textbf{ score} $\ast$score\+\_\+user)
|
||||
int \textbf{ move} (char $\ast$$\ast$tab, \textbf{ vect} $\ast$player\+Pos, \textbf{ vect} direction, \textbf{ score} $\ast$score\+\_\+user)
|
||||
\begin{DoxyCompactList}\small\item\em Cette fonction effectue les deplacements du joueur et des boites en fonction de la situation. \end{DoxyCompactList}\item
|
||||
int \textbf{ in\+Game\+Loop} (char $\ast$$\ast$tab2d, \textbf{ vect} $\ast$dim\+\_\+tab, \textbf{ vect} $\ast$player\+Pos, \textbf{ vect} $\ast$targets, int nbr\+\_\+targets, \textbf{ dis} $\ast$display\+\_\+user, \textbf{ score} $\ast$score\+\_\+user, bool menu)
|
||||
\begin{DoxyCompactList}\small\item\em La fonction permet de faire la boucle de jeu et le menu. \end{DoxyCompactList}\item
|
||||
int \textbf{ in\+Editor\+Loop} (char $\ast$$\ast$tab2d, \textbf{ vect} $\ast$dim\+\_\+tab, \textbf{ vect} $\ast$player\+Pos, \textbf{ vect} $\ast$targets, int nbr\+\_\+targets, \textbf{ dis} $\ast$display\+\_\+user, \textbf{ score} $\ast$score\+\_\+user, int num\+\_\+fichier)
|
||||
\begin{DoxyCompactList}\small\item\em La fonction permet de faire la boucle de l\textquotesingle{}éditeur. \end{DoxyCompactList}\item
|
||||
int \textbf{ title\+Screen} (\textbf{ dis} $\ast$display\+\_\+user)
|
||||
\begin{DoxyCompactList}\small\item\em La fonction permet d\textquotesingle{} afficher le title screen. \end{DoxyCompactList}\item
|
||||
bool \textbf{ is\+Win} (char $\ast$$\ast$tab2d, \textbf{ vect} $\ast$targets, int nbr\+\_\+targets)
|
||||
\begin{DoxyCompactList}\small\item\em Cette fonction verrifie si la partie est gagnante. \end{DoxyCompactList}\item
|
||||
bool \textbf{ islose} (char $\ast$$\ast$tab2d, const int N)
|
||||
@@ -47,6 +52,9 @@ void \textbf{ win\+Or\+Lose\+Loop} (\textbf{ dis} $\ast$display\+\_\+user, \text
|
||||
\begin{DoxyCompactList}\small\item\em Fonction de loop pour la win ou la lose. \end{DoxyCompactList}\item
|
||||
\label{function_8c_aeac9c46be252cd970406e3a2391b8e8c}
|
||||
unsigned int {\bfseries score\+Calculator} (\textbf{ score} $\ast$score\+\_\+user, bool win)
|
||||
\item
|
||||
\label{function_8c_acdbf299b1c7d8d708c4e7b014c43911a}
|
||||
unsigned int {\bfseries score\+Calculator\+Cyp} (\textbf{ score} $\ast$score\+\_\+user, bool win)
|
||||
\end{DoxyCompactItemize}
|
||||
|
||||
|
||||
@@ -145,6 +153,40 @@ Cette fontion permet de liberer l\textquotesingle{}espace tu tableau 2D de char.
|
||||
\begin{DoxyReturn}{Renvoie}
|
||||
Void.
|
||||
\end{DoxyReturn}
|
||||
\index{function.c@{function.c}!inEditorLoop@{inEditorLoop}}
|
||||
\index{inEditorLoop@{inEditorLoop}!function.c@{function.c}}
|
||||
\doxysubsubsection{inEditorLoop()}
|
||||
{\footnotesize\ttfamily \label{function_8c_aeba9362e7ee8b3d96352fd608b73a5c7}
|
||||
int in\+Editor\+Loop (\begin{DoxyParamCaption}\item[{char $\ast$$\ast$}]{tab2d}{, }\item[{\textbf{ vect} $\ast$}]{dim\+\_\+tab}{, }\item[{\textbf{ vect} $\ast$}]{player\+Pos}{, }\item[{\textbf{ vect} $\ast$}]{targets}{, }\item[{int}]{nbr\+\_\+targets}{, }\item[{\textbf{ dis} $\ast$}]{display\+\_\+user}{, }\item[{\textbf{ score} $\ast$}]{score\+\_\+user}{, }\item[{int}]{num\+\_\+fichier}{}\end{DoxyParamCaption})}
|
||||
|
||||
|
||||
|
||||
La fonction permet de faire la boucle de l\textquotesingle{}éditeur.
|
||||
|
||||
|
||||
\begin{DoxyParams}{Paramètres}
|
||||
{\em tab2d} & Le tableau 2d carre. \\
|
||||
\hline
|
||||
{\em N} & LE nombre d\textquotesingle{}element de tab2d. \\
|
||||
\hline
|
||||
{\em player\+Pos} & La position de depart du joueur. \\
|
||||
\hline
|
||||
{\em targets} & Le tableau de toutes les positions des points d\textquotesingle{}interer de la maps. \\
|
||||
\hline
|
||||
{\em int} & nbr\+\_\+targets Le nombre de point d\textquotesingle{}interer. \\
|
||||
\hline
|
||||
{\em display\+\_\+user} & Tout les information SDL pour afficher le jeu. \\
|
||||
\hline
|
||||
{\em score\+\_\+user} & Toute les données nécessaire pour calculer le score fini du joueur. \\
|
||||
\hline
|
||||
{\em num\+\_\+fichier} & Simplement le numéro de la map actuel. \\
|
||||
\hline
|
||||
\end{DoxyParams}
|
||||
\begin{DoxyReturn}{Renvoie}
|
||||
renvoie -\/2 ce qui signifie l\textquotesingle{}editeur
|
||||
\end{DoxyReturn}
|
||||
Voici le graphe d\textquotesingle{}appel pour cette fonction \+:
|
||||
% FIG 3
|
||||
\index{function.c@{function.c}!inGameLoop@{inGameLoop}}
|
||||
\index{inGameLoop@{inGameLoop}!function.c@{function.c}}
|
||||
\doxysubsubsection{inGameLoop()}
|
||||
@@ -178,7 +220,7 @@ La fonction permet de faire la boucle de jeu et le menu.
|
||||
L\textquotesingle{}indice de la map si c\textquotesingle{}est un menu, sinon renvoie -\/1
|
||||
\end{DoxyReturn}
|
||||
Voici le graphe d\textquotesingle{}appel pour cette fonction \+:
|
||||
% FIG 3
|
||||
% FIG 4
|
||||
\index{function.c@{function.c}!islose@{islose}}
|
||||
\index{islose@{islose}!function.c@{function.c}}
|
||||
\doxysubsubsection{islose()}
|
||||
@@ -231,8 +273,8 @@ True si le joueur a remplis tout les points d\textquotesingle{}interer, false si
|
||||
\index{function.c@{function.c}!move@{move}}
|
||||
\index{move@{move}!function.c@{function.c}}
|
||||
\doxysubsubsection{move()}
|
||||
{\footnotesize\ttfamily \label{function_8c_ac93ca31d854d91eedf3babda7511407d}
|
||||
void move (\begin{DoxyParamCaption}\item[{char $\ast$$\ast$}]{tab}{, }\item[{\textbf{ vect} $\ast$}]{player\+Pos}{, }\item[{\textbf{ vect}}]{direction}{, }\item[{\textbf{ score} $\ast$}]{score\+\_\+user}{}\end{DoxyParamCaption})}
|
||||
{\footnotesize\ttfamily \label{function_8c_a9c9b1fdde1684178393ffe6104ab615d}
|
||||
int move (\begin{DoxyParamCaption}\item[{char $\ast$$\ast$}]{tab}{, }\item[{\textbf{ vect} $\ast$}]{player\+Pos}{, }\item[{\textbf{ vect}}]{direction}{, }\item[{\textbf{ score} $\ast$}]{score\+\_\+user}{}\end{DoxyParamCaption})}
|
||||
|
||||
|
||||
|
||||
@@ -250,17 +292,12 @@ Cette fonction effectue les deplacements du joueur et des boites en fonction de
|
||||
\hline
|
||||
\end{DoxyParams}
|
||||
\begin{DoxyReturn}{Renvoie}
|
||||
Void
|
||||
int return 1 si le joueur n\textquotesingle{}a pas bouger.
|
||||
\end{DoxyReturn}
|
||||
Voici le graphe d\textquotesingle{}appel pour cette fonction \+:\nopagebreak
|
||||
\begin{figure}[H]
|
||||
\begin{center}
|
||||
\leavevmode
|
||||
\includegraphics[width=242pt]{function_8c_ac93ca31d854d91eedf3babda7511407d_cgraph}
|
||||
\end{center}
|
||||
\end{figure}
|
||||
Voici le graphe d\textquotesingle{}appel pour cette fonction \+:
|
||||
% FIG 5
|
||||
Voici le graphe des appelants de cette fonction \+:
|
||||
% FIG 4
|
||||
% FIG 6
|
||||
\index{function.c@{function.c}!nullScore@{nullScore}}
|
||||
\index{nullScore@{nullScore}!function.c@{function.c}}
|
||||
\doxysubsubsection{nullScore()}
|
||||
@@ -300,7 +337,7 @@ La fonction fait une addition de vecteur, (x1+x2, y1+y2).
|
||||
vect Un vecteur de l\textquotesingle{}addition de one et two.
|
||||
\end{DoxyReturn}
|
||||
Voici le graphe des appelants de cette fonction \+:
|
||||
% FIG 5
|
||||
% FIG 7
|
||||
\index{function.c@{function.c}!timeToText@{timeToText}}
|
||||
\index{timeToText@{timeToText}!function.c@{function.c}}
|
||||
\doxysubsubsection{timeToText()}
|
||||
@@ -320,7 +357,25 @@ Cette fonction renvois transforme le forma time en texte. (min\+:sec)
|
||||
char Le string du texte.
|
||||
\end{DoxyReturn}
|
||||
Voici le graphe des appelants de cette fonction \+:
|
||||
% FIG 6
|
||||
% FIG 8
|
||||
\index{function.c@{function.c}!titleScreen@{titleScreen}}
|
||||
\index{titleScreen@{titleScreen}!function.c@{function.c}}
|
||||
\doxysubsubsection{titleScreen()}
|
||||
{\footnotesize\ttfamily \label{function_8c_ad3517d7c8da5b33a96d376d7b07911c1}
|
||||
int title\+Screen (\begin{DoxyParamCaption}\item[{\textbf{ dis} $\ast$}]{display\+\_\+user}{}\end{DoxyParamCaption})}
|
||||
|
||||
|
||||
|
||||
La fonction permet d\textquotesingle{} afficher le title screen.
|
||||
|
||||
|
||||
\begin{DoxyParams}{Paramètres}
|
||||
{\em display\+\_\+user} & Tout les information SDL pour afficher le jeu. \\
|
||||
\hline
|
||||
\end{DoxyParams}
|
||||
\begin{DoxyReturn}{Renvoie}
|
||||
renvoie -\/3 ce qui signifie le title screen
|
||||
\end{DoxyReturn}
|
||||
\index{function.c@{function.c}!winOrLoseLoop@{winOrLoseLoop}}
|
||||
\index{winOrLoseLoop@{winOrLoseLoop}!function.c@{function.c}}
|
||||
\doxysubsubsection{winOrLoseLoop()}
|
||||
|
||||
Reference in New Issue
Block a user