| Commit message (Collapse) | Author | Age | Files | Lines | |
|---|---|---|---|---|---|
| * | player: Add missing headerHEADmaster | Xavier Del Campo Romero | 2024-01-30 | 2 | -0/+2 |
| | | | | | As required by rand(3). | ||||
| * | human_player_gui.c: Rename on_exit to on_btn_exit | Xavier Del Campo Romero | 2024-01-30 | 1 | -2/+2 |
| | | | | | | Surprisingly, glibc declares on_exit(3) as a non-portable function on stdlib.h. | ||||
| * | Big rushed update | Xavier Del Campo Romero | 2024-01-28 | 6 | -22/+205 |
| | | |||||
| * | Add btn_small | Xavier Del Campo Romero | 2024-01-27 | 2 | -5/+20 |
| | | |||||
| * | Remove stale unit and building types | Xavier Del Campo Romero | 2024-01-27 | 1 | -37/+0 |
| | | |||||
| * | Replace "unsigned int" with "unsigned" | Xavier Del Campo Romero | 2024-01-27 | 1 | -1/+1 |
| | | |||||
| * | Remove hp | Xavier Del Campo Romero | 2024-01-27 | 2 | -36/+2 |
| | | |||||
| * | Remove resource, tech and old game resources | Xavier Del Campo Romero | 2024-01-27 | 6 | -508/+44 |
| | | |||||
| * | WIP | Xavier Del Campo Romero | 2022-11-01 | 3 | -24/+16 |
| | | |||||
| * | Remap calls to pad/mouse/keyboard to input | Xavier Del Campo Romero | 2022-09-20 | 3 | -16/+27 |
| | | |||||
| * | human_player_gui.c: use gui_container for top gui_bar | Xavier Del Campo Romero | 2022-07-02 | 1 | -9/+16 |
| | | |||||
| * | human_player_gui.c: fix segfault when selecting one unit | Xavier Del Campo Romero | 2022-06-27 | 1 | -1/+1 |
| | | | | | | | | Checking against `sel` is just plain wrong, since it always expected to be non-NULL, since `h->sel` is an array defined in `struct human_player`. Instead, `sel->d.i` is the pointer that should be checked. | ||||
| * | human_player: deprecate memset(3) for zero-init | Xavier Del Campo Romero | 2022-06-26 | 2 | -7/+12 |
| | | |||||
| * | human_player.c: reset deselected instances | Xavier Del Campo Romero | 2022-06-26 | 1 | -0/+9 |
| | | |||||
| * | Fix hp bar not being displayed when carrying | Xavier Del Campo Romero | 2022-06-26 | 1 | -7/+6 |
| | | |||||
| * | Revamp gui component | Xavier Del Campo Romero | 2022-06-26 | 4 | -4/+368 |
| | | | | | | | | | | | | | | | | | | | | | `gui` was tighly coupled to game logic, and could not be extended for other purposes. Therefore, a generic GUI implementation, loosely inspired by well-known GUI frameworks such as GTK, is now provided, with the following properties: - Does not depend on dynamic or static memory allocation, only automatic (i.e., stack) memory allocation required. - Portable among existing implementations. - Simple to extend. - Tiny memory footprint. `gui` is now composed by GUI elements that can be chained to form a tree structure. This is useful e.g.: to calculate X/Y coordinates for a given GUI element given its parent(s). This commit also refactors the older implementation, moving game-specific logic into `player` and making use of the new component. | ||||
| * | Deprecate memset(3) over C99 compound literals for zero-init | Xavier Del Campo Romero | 2022-06-26 | 1 | -1/+1 |
| | | | | | | Using memset(3) does not ensure pointers are assigned to NULL for all platforms. | ||||
| * | player: limit data sizes for resources and population | Xavier Del Campo Romero | 2022-06-26 | 3 | -3/+6 |
| | | | | | | - All platforms should allow for the same resources. - Population is not expected to exceed UCHAR_MAX on any platform. | ||||
| * | peripheral: provide common actions | Xavier Del Campo Romero | 2022-06-24 | 2 | -36/+9 |
| | | | | | | | Whereas some actions are context-specific (e.g.: selecting a player), some are context-independent and can be executed for all screens (e.g.: exiting the game). | ||||
| * | camera: remove dependency against terrain | Xavier Del Campo Romero | 2022-06-12 | 1 | -0/+1 |
| | | | | | | This will allow using camera for purposes other than showing the game map. | ||||
| * | Split peripheral-related logic into its own component | Xavier Del Campo Romero | 2022-06-12 | 2 | -62/+25 |
| | | | | | | | | | | | | This has several advantages: - `camera` no longer needs to define public functions for each peripheral type. - Peripheral-related is now no longer tighly coupled to human_player, so peripheral logic can be reused elsewhere e.g.: on menus. - Makes camera_update_touch consistent compared to equivalent functions, since now `pan` has now been moved to `camera` (as it should be). | ||||
| * | Remove unused minor stuff | Xavier Del Campo Romero | 2022-03-31 | 1 | -1/+0 |
| | | |||||
| * | Fix exit condition | Xavier Del Campo Romero | 2022-03-31 | 1 | -1/+1 |
| | | |||||
| * | Implement touch controls | Xavier Del Campo Romero | 2022-03-31 | 2 | -13/+105 |
| | | |||||
| * | Add support for keyboard and mouse | Xavier Del Campo Romero | 2022-03-30 | 3 | -53/+193 |
| | | |||||
| * | Add project source code | Xavier Del Campo Romero | 2022-03-30 | 5 | -0/+838 |
