summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-05-16added default font to make the project runOlivier Gayot
This is not the definitive one but it allows the game to start. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-05-16makefile: updated the dependencies handling methodOlivier Gayot
the makefile now generates .d files and is more robust Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-11rewitten the code of the selection changeOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-11coding rules: stop at 78 colsrewriteOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-11renamed the rects inside the struct positionsOlivier Gayot
it is redundant in thus inconvenient to repeat 'position' inside a structure named position. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-11remove or replace a lot of code for the initializationOlivier Gayot
many structures or positions were not revelant anymore and thus have been removed. some positions were not relative to each other it is sometimes not meaningful to put surfaces in the global scope when they only need to be used once. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-11use the target mask to restrict the possible targetsOlivier Gayot
The <TAB> and <D> buttons are bound to the action which switches between a targetted team and a targetted character. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10renamed the output binaryOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10allow to pass the resolution as argumentsOlivier Gayot
example (for my netbook): $ ./a.out 1024 600 Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10added esunaOlivier Gayot
for now on, the cast only cures poison Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10emphasize the categories in the action listOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10do not handle font I/O inside the game.Olivier Gayot
the fonts (actually the font) is opened at startup and closed at shutdown. This fixes possible crashes during the game if a font file is removed/moved. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10cleaned the initialization / shutdown a littleOlivier Gayot
The initialized surfaces are converted to display format so that they are ready for fastblit. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10drop events produced during sleepsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10hide the action frame when selecting a targetOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10added "cyanmure" magicOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-10added "Defend" actionOlivier Gayot
physical and magical damages are divided by 2 when a character is on defensive state. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09added UltimaOlivier Gayot
this cast deals non elemental magic damages to every opponent Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09change the type of target of "Choc"Olivier Gayot
Choc only damages one target. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09select the default target according to the type of selectionOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09pass the target type to select_targetOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09allow to display a multiple selectionOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09select a target using a structure instead of an indexOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09handle the different type of targetsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09implement a way to define who is targetable by an actionOlivier Gayot
we can specify who are the targets of an action by setting the field entry->action.target it can be a combination of one or more specifiers, such as: one team an eneny self everyone Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09replace the code of the artificial "intellligence"Olivier Gayot
the new function of the AI chooses a random target in the adversary team and use "attack" on it. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09added forgotten header fileOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09use a generic way to handle a turn from a cpu or a playerOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-09use a new field which contains the playing characterOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08move some functions and headers so that the compilation is quickerOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08deactivate the display of the mapOlivier Gayot
since the map is not used now, no need to display it Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08blit the background only once (no need for a weird function)Olivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08add new pointers to screen and backgroundOlivier Gayot
make the old ones (Pfondjeu and Pecran) deprecated but keep them so the code continues working properly. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08handle the two teams the same wayOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08create the red surface for the warrior gobelinsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08mark non public functions as staticOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08fixed infinite loop when some enemy is deadOlivier Gayot
Because the function Fjouer still relies on some of the deprecated features, some bugs arise. fixed by replacing by the new features. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08initialize the items (aka objects) of the teamsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08removed unused deprecated constantsOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08fix invalid write in new_enemy_team and in FjouerOlivier Gayot
in the function `new_enemy_team()', we used to loop through the enemies while the incrementer is less or equal to the count. However, since there are `count' elements, we need to stop the loop when the incrementer gets equal to `count' the same bug is present in `Fjouer()' when checking if the player wins. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08do not free the pointer returned by SDL_SetVideoModeOlivier Gayot
The pointer is automatically freed by the SDL library 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-08add callback functions associated to a leaf actionOlivier Gayot
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08fix: the game stopped when we cancelled a root actinOlivier Gayot
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-08fix buggy behaviour in compute_damagesOlivier Gayot
we forgot to remove the old version of the computation regarding the affinities (aka. using the affinity as a coefficient). fixed by removing the old version. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
2015-01-08fix invalid display of the affinitiesOlivier Gayot
we used to loop through the elements in our outer loop and the affinities in the inner one. However since, the display is done line by line, we have to do the contrary. Signed-off-by: Olivier Gayot <duskcoder@gmail.com>