Skip to content

better cpp mod config reader#33

Merged
fesily merged 18 commits intomasterfrom
Preview
Apr 8, 2026
Merged

better cpp mod config reader#33
fesily merged 18 commits intomasterfrom
Preview

Conversation

@fesily
Copy link
Copy Markdown
Owner

@fesily fesily commented Apr 4, 2026

  • Thread args.force to download_target() call so --force/-f CLI flag takes effect

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves how the injector resolves/modifies the LuaJIT mod configuration by introducing a richer config resolution path (modinfo defaults → luajit_config.json → save/modoverrides → env/cmd overrides), and by generating the C++ modinfo.hpp from Mod/modinfo.lua during the build.

Changes:

  • Added build-time generation of src/modinfo.hpp from Mod/modinfo.lua and wired it into the Injector build.
  • Reworked GameJitModConfig to load/merge config from client save files or server modoverrides.lua, plus env/cmd overrides.
  • Updated config schema keys (e.g., DisableJITWhenServer, AlwaysEnableMod) and adjusted related tooling/scripts.

Reviewed changes

Copilot reviewed 22 out of 25 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
tools/update_steam_paths.py Switches CMake update logic to insert/update an auto-updated GAME_DIR block.
tools/modinfo2cpp.lua Generates a C++ header from modinfo.lua configuration options.
tools/download_frida_gum.py Adds cache-bypass support when downloading Frida Gum (with a force flag).
tools/Creater/update_signatures.sh Quotes executable paths and skips missing files.
tools/Creater/CMakeLists.txt Adjusts signature update invocation paths/working directory.
src/modinfo.hpp Removes the checked-in generated header (now generated during build).
src/DontStarveInjector/luajit_config.hpp Removes unused fields from luajit_config.
src/DontStarveInjector/luajit_config.cpp Changes JSON field names used for config serialization/deserialization.
src/DontStarveInjector/GameOpenGl.cpp Reads ANGLE backend selection from GameJitModConfig.
src/DontStarveInjector/gameModConfig.hpp Expands the resolved config model and declares load/write helpers.
src/DontStarveInjector/gameModConfig.cpp Implements multi-source config resolution and save/modoverrides parsing/writing.
src/DontStarveInjector/GameLuaModule.cpp Adds Lua table parsing/serialization helpers for config save/modoverrides I/O.
src/DontStarveInjector/GameLuaInjectFramework.lua Formatting-only churn in the diff.
src/DontStarveInjector/game_info.cpp Adjusts Linux game info offset scanning storage types; adds Win stub.
src/DontStarveInjector/DontStarveInjector.cpp Uses GameJitModConfig for server disable logic; moves signature init earlier.
src/DontStarveInjector/CMakeLists.txt Ensures Injector depends on create_modinfo_hpp.
Mod/modmain.lua Writes updated config key names into luajit_config.json.
Mod/bin64/linux/signatures_server.json Updates signatures and version for server.
Mod/bin64/linux/signatures_client.json Updates signatures and version for client.
CMakeLists.txt Adds create_modinfo_hpp custom command/target.
cmake/custom-triplets/x64-windows-custom.cmake Makes VCPKG_BUILD_TYPE=release conditional for CI.
.gitignore Ignores generated src/modinfo.hpp.
.gitattributes Normalizes line endings by file type.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

fesily and others added 3 commits April 4, 2026 22:51
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@fesily fesily merged commit 0a95b0f into master Apr 8, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants