summaryrefslogtreecommitdiff
path: root/prototypes.h
AgeCommit message (Collapse)Author
2015-01-08initialize the items (aka objects) of the teamsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08handle the selection of a target in a generic way.Olivier Gayot
we do not split the code of the selection of a target anymore. Each action now does a very simple thing and as much efficiently as possible. every old function that are not used anymore have been removed. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08remove old functions to select an entryOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08use a generic way to navigate through entriesOlivier Gayot
entries are actually any action or subaction that can be performed. Attack, White Magic and so on are root actions. Fire, Ice X are subactions of Black Magic. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08use the objects assigned to the teams instead of a common arrayOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08improve code and fix numerous bugsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08update the damages handlingOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08use the new enemy team instead of the old array of ENEMIESOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07added the current user to the team structureOlivier Gayot
the current character is generated randomly at the initialization of the team. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07make team blitting and characters highlighting genericOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07generate the affinities during the creation of the charactersOlivier Gayot
do not differenciate between the players and the enemies as well Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07use a team / character model instead of an array of personnagesOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07clean the code and fix bugsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07do not pass a pointer to standard type when a copy is possibleOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07simplify the code of menuchoixpersosOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07fixed some compilation warningsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07replaced function inverse() by macroOlivier Gayot
There was multiple problems with this function: void inverse(int *bool); First, we use "bool", which is actually a standard type, as the identifier. Then, we cannot pass different types to the function without cast. Then, inverse is not a meaninful name. At last, we have to pass the address of the variable we want to inverse. Fixed all these points by replacing the function by a macro : #define inverse_boolean(_b) /* impl */ Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-07Fix segmentation fault when the game startsOlivier Gayot
Since no prototype for Fchangercurseurpersos was given, a nasty exception was raised when we passed an invalid data to this function. By providing its prototype, the compiler gives us a clue about the usage of an invalid pointer type that we can fix. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2014-10-26fix segmentation fault issued at startupOlivier Gayot
we used to try to open an image whose filename is wrong. Since we do not check the return of this function, the program crashes. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2014-10-26game: remove useless checksOlivier Gayot
it is safe to pass a null pointer to SDL_FreeSurface() BTW: change the format of the files from dos to unix Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2014-10-26game: Add a buildable version of the agmeOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>