| Commit message (Collapse) | Author | Age | Files | Lines | ||
|---|---|---|---|---|---|---|
| ... | ||||||
| * | font: implement font_dim | Xavier Del Campo Romero | 2022-06-29 | 2 | -16/+46 | |
| | | ||||||
| * | Deprecate memset(3) for zero-init | Xavier Del Campo Romero | 2022-06-27 | 2 | -2/+2 | |
| | | ||||||
| * | 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 | |
| | | ||||||
| * | ps1/heap.c: bump heap size | Xavier Del Campo Romero | 2022-06-26 | 1 | -1/+1 | |
| | | ||||||
| * | Implement main menu | Xavier Del Campo Romero | 2022-06-26 | 8 | -12/+106 | |
| | | ||||||
| * | terrain: fix wrong rendering | Xavier Del Campo Romero | 2022-06-26 | 1 | -2/+2 | |
| | | | | | | The older implementation would leave empty areas on the right side of the screen. | |||||
| * | font: deprecate font_printf | Xavier Del Campo Romero | 2022-06-26 | 2 | -20/+0 | |
| | | | | | This function is no longer needed since `gui` was revamped. | |||||
| * | Revamp gui component | Xavier Del Campo Romero | 2022-06-26 | 24 | -599/+1245 | |
| | | | | | | | | | | | | | | | | | | | | | `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. | |||||
| * | font: add font_puts | Xavier Del Campo Romero | 2022-06-26 | 2 | -0/+7 | |
| | | ||||||
| * | peripheral.c: initialize common members only | Xavier Del Campo Romero | 2022-06-26 | 1 | -1/+1 | |
| | | | | | Other members will be initialized according to peripheral configuration. | |||||
| * | Deprecate memset(3) over C99 compound literals for zero-init | Xavier Del Campo Romero | 2022-06-26 | 3 | -3/+3 | |
| | | | | | | 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. | |||||
| * | camera: implement fixed cursor movement | Xavier Del Campo Romero | 2022-06-24 | 3 | -3/+77 | |
| | | | | | | | | | | | | On platforms with PERIPHERAL_TYPE_PAD, navigating through menus and options can be cumbersome if moving the cursor freely around the screen. Therefore, this commit instead defines a list of (X, Y) coordinates that the cursor can jump to. The implementation also attempts to guess which direction the cursor should jump to for the previous/next point, and hence determine which button should be pressed by the user. | |||||
| * | camera.c: refactor cursor_init | Xavier Del Campo Romero | 2022-06-24 | 1 | -4/+15 | |
| | | | | | So that uninitialized members are set to 0. | |||||
| * | peripheral: provide common actions | Xavier Del Campo Romero | 2022-06-24 | 6 | -38/+38 | |
| | | | | | | | 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). | |||||
| * | README.md: add copyright notice | Xavier Del Campo Romero | 2022-06-24 | 1 | -7/+12 | |
| | | ||||||
| * | README.md: update according to current status | Xavier Del Campo Romero | 2022-06-24 | 1 | -2/+8 | |
| | | ||||||
| * | cmake/ps1.cmake: use add_library for libpsx.a | Xavier Del Campo Romero | 2022-06-19 | 1 | -5/+7 | |
| | | ||||||
| * | Deprecate <TARGET>_BUILD in favor of CMAKE_TOOLCHAIN_FILE | Xavier Del Campo Romero | 2022-06-19 | 2 | -23/+32 | |
| | | ||||||
| * | camera: remove dependency against terrain | Xavier Del Campo Romero | 2022-06-12 | 6 | -9/+20 | |
| | | | | | | 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 | 13 | -78/+165 | |
| | | | | | | | | | | | | 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). | |||||
| * | CMakeLists.txt: limit libraries linked to by ${PROJECT_NAME} | Xavier Del Campo Romero | 2022-06-12 | 1 | -1/+2 | |
| | | | | | | Old behaviour was linking to all components, but main.c currently only needs a few of them. | |||||
| * | sdl-1.2/sound.c: use SDL_WasInit | Xavier Del Campo Romero | 2022-06-11 | 1 | -4/+2 | |
| | | ||||||
| * | sdl-1.2: return to original dimensions on fullscreen exit | Xavier Del Campo Romero | 2022-06-11 | 1 | -3/+8 | |
| | | ||||||
| * | Implement button component | Xavier Del Campo Romero | 2022-06-11 | 6 | -1/+170 | |
| | | ||||||
| * | res: add btn_{left,mid,right} | Xavier Del Campo Romero | 2022-06-11 | 1 | -0/+27 | |
| | | ||||||
| * | res/CMakeLists.txt: do not use transparency for sel_mid_v | Xavier Del Campo Romero | 2022-06-11 | 1 | -1/+1 | |
| | | ||||||
| * | README.md: reflect current status | Xavier Del Campo Romero | 2022-06-08 | 1 | -11/+18 | |
| | | ||||||
| * | win9x.cmake: remove unneeded dependencies | Xavier Del Campo Romero | 2022-06-08 | 1 | -5/+1 | |
| | | ||||||
| * | win9x.cmake: use target commands for SDL and SDL_mixer | Xavier Del Campo Romero | 2022-06-08 | 1 | -8/+12 | |
| | | | | | | | | | | | | | Since libSDL.a and libSDL_mixer.a are compiled separately from this project, some hacks had been used to get the build running. However, this approach did not make proper use of target-level properties, which are encouraged according to modern CMake standards over global-level commands such as include_directories() or link_libraries(). OTOH, Win32 dependencies were being imported using link_libraries(), but they in fact are SDL dependencies, so target_link_libraries() can be used instead. | |||||
| * | pad/CMakeLists.txt: add missing call to target_link_libraries() | Xavier Del Campo Romero | 2022-06-08 | 1 | -0/+1 | |
| | | ||||||
| * | CMakeLists.txt: assume native build by default | Xavier Del Campo Romero | 2022-06-08 | 1 | -5/+4 | |
| | | | | | | | | | | This has been decided to make the de-facto standard CMake build process (shown below) possible. $ mkdir build $ cd build/ $ cmake .. | |||||
| * | CMakeLists.txt: build host tools as ExternalProject | Xavier Del Campo Romero | 2022-06-08 | 3 | -3/+14 | |
| | | ||||||
| * | CMakeLists.txt: move target-specific logic away | Xavier Del Campo Romero | 2022-06-07 | 4 | -7/+9 | |
| | | ||||||
| * | Split CMakeLists.txt into platform-specific *.cmake | Xavier Del Campo Romero | 2022-05-24 | 4 | -83/+82 | |
| | | ||||||
| * | Make gfx_draw return int | Xavier Del Campo Romero | 2022-05-24 | 4 | -4/+11 | |
| | | ||||||
| * | Use realloc(3) directly | Xavier Del Campo Romero | 2022-05-24 | 1 | -7/+1 | |
| | | | | | It is simply not true realloc(3) cannot be used with NULL pointers. | |||||
| * | font.c: avoid several va_list in favor of large buffer | Xavier Del Campo Romero | 2022-05-24 | 1 | -32/+6 | |
| | | ||||||
| * | Allow systems without sound support | Xavier Del Campo Romero | 2022-05-24 | 4 | -11/+32 | |
| | | ||||||
| * | Remove unused minor stuff | Xavier Del Campo Romero | 2022-03-31 | 2 | -2/+1 | |
| | | ||||||
| * | resource.c: decouple collbox from sprite dimensions | Xavier Del Campo Romero | 2022-03-31 | 1 | -6/+26 | |
| | | ||||||
| * | Fix exit condition | Xavier Del Campo Romero | 2022-03-31 | 1 | -1/+1 | |
| | | ||||||
| * | Implement touch controls | Xavier Del Campo Romero | 2022-03-31 | 9 | -18/+177 | |
| | | ||||||
| * | Implement sub-tile collboxes | Xavier Del Campo Romero | 2022-03-30 | 9 | -7/+104 | |
| | | | | | These will be later used by the pathfinding algorithm. | |||||
| * | Rename MAP_{X|Y} to MAP_{W|H} | Xavier Del Campo Romero | 2022-03-30 | 3 | -8/+8 | |
| | | ||||||
| * | camera: implement mouse support | Xavier Del Campo Romero | 2022-03-30 | 1 | -2/+27 | |
| | | ||||||
| * | Move CURSOR_{WIDTH|HEIGHT} to library scope | Xavier Del Campo Romero | 2022-03-30 | 2 | -13/+13 | |
| | | ||||||
