Commit graph

11 commits

Author SHA1 Message Date
Matt Penny 4e9e9d32d6 ASM: simplify, document, start integrating with CMake
* Refactor entry point
* Remove unused code
* Reformat level header to be more clear, and add more comments

Looks like assembling with CMake will require some changes to the
assembler flags, and possibly some manual dependency specification.
2024-10-19 02:38:52 -04:00
Matt Penny 22ea93d19f CMake: automatically find programs used in build
Blender 3.6 and ImageMagick 6 versions are also enforced
2024-10-17 21:04:48 -04:00
Matt Penny 259181f2b5 CMake: add find module for libultra, improve N64 toolchain file
* Less hard-coding when searching for libultra
* Proper compiler, assembler, and linker flags
* Multiple build types
* Support for multi-config generators
2024-10-17 18:14:15 -04:00
Matt Penny 1d0b22df61 Generate dynamic model lists with CMake, + refactor
* When building with CMake, dynamic model lists are now generated
* Factored common code out of generate_*_list.js files to deduplicate
* Better separated generated model lists from main game code
    `dynamic_asset_data.c` and `dynamic_animated_asset_data.c`
    previously #included the corresponding generated headers, and
    `dynamic_asset_loader.c` declared externs for the contents.

    This messiness was likely done so the generated code would be built
    automatically (the Makefile globs all C files under `src/`).

    Now, model list data is output to C source files which are built
    explicitly. This, with some refactoring, allows the previously
    mentioned source files and externs to be removed.

    This is a bit hacky in the Makefile but will be automatic under
    CMake by using target properties.
* Reorganized some files under `tools/`
2024-10-05 21:11:49 -04:00
Matt Penny bc2052527c Generate game version for CMake builds and fix generated level names
With CMake, the game version is stored in a generated header file so
dependencies on it are kept track of automatically.

The game now compiles when using CMake but does not link.

Generated code dependencies are not hooked up yet and corresponding
targets need to be built manually.
2024-09-25 22:24:16 -04:00
Matt Penny 9e633b868b Work on CMake compilation
About half of the source files compile.
Need to hook up generated code, compiler definitions, and dependencies.
2024-09-24 01:27:18 -04:00
Matt Penny fa0940fe90 Work on CMake conversion: test chambers
Incidental changes along the way:
* Move `export_level.lua` to `tools/level_scripts/`
* Small reorganizations/fixes to existing `CMakeLists.txt` files
* Support passing absolute paths to level export
2024-09-13 00:53:55 -04:00
Matt Penny dea0c3591d Work on CMake conversion: sound transformation, conversion, and table generation
Some parts need to be cleaned up/removed/streamlined after the CMake
build can build the game on its own and compatibility with what the
old makefile does is no longer needed.
2024-09-12 02:17:28 -04:00
Matt Penny 0d2cd6efe0 Work on CMake conversion: sound transformation 2024-09-09 23:34:16 -04:00
Matt Penny 2fcea7f9d2 Work on CMake conversion: material generation 2024-09-07 20:00:45 -04:00
Matt Penny b999e139fa Work on CMake conversion: VPK extract and texture conversion 2024-09-06 01:26:08 -04:00