Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Config JSON #31

Merged
merged 28 commits into from
Jan 16, 2023
Merged

Config JSON #31

merged 28 commits into from
Jan 16, 2023

Conversation

ithinkandicode
Copy link
Collaborator

@ithinkandicode ithinkandicode commented Jan 15, 2023

Note: I've tested this extensively, incl. with the CLI args, so there shouldn't be any issues or errors unless I've completely missed something

Config JSONs

  • Adds support for per-mod config JSONs in res://configs. View the README for full details.
  • Provides a new utility func get_mod_config(mod_id, key).
    • This can be used to get the full data, or data from a specific key.
    • Includes extensive validation, with error messages and codes listed in the README.
  • Supports setting default options via a new required manifest key, config_defaults.
    • If set, using get_mod_config when no custom JSON file is present will return your manifest's defaults instead.
  • Includes support for overwriting the configs dir with a CLI arg, --configs-path.
  • Closes Config JSON #15.

Misc Changes

  • Lots of improvements to README:
    • Add table of contents
    • Docs for mod_log and dev_log methods
    • New sections for CLI Args & Config Options
    • Overview table for Helper Methods
    • Change spaces to tabs for the JSON examples
  • Adds or improves a few comments
  • Adds required manifest key: namespace (AuthorName)
  • Adds required manifest key: compatible_modloader_version.

Breaking Changes

  • manifest.json key: namespace
  • manifest.json key: extra.godot.config_defaults
  • manifest.json key: extra.godot.compatible_modloader_version

Copy link
Member

@otDan otDan left a comment

Choose a reason for hiding this comment

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

After going through all of it, it seems like everything is correctly in place and is well commented, as this is a big pr, I will probably wait for KANA to go through all of it too before approving.

@otDan otDan requested a review from KANAjetzt January 15, 2023 19:35
@ithinkandicode ithinkandicode mentioned this pull request Jan 16, 2023
5 tasks
loader/mod_loader.gd Outdated Show resolved Hide resolved
loader/mod_loader.gd Outdated Show resolved Hide resolved
loader/mod_loader.gd Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
Copy link
Collaborator

@Qubus0 Qubus0 left a comment

Choose a reason for hiding this comment

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

good stuff

@ithinkandicode ithinkandicode merged commit 3e6542b into GodotModding:main Jan 16, 2023
@ithinkandicode ithinkandicode deleted the config-json branch January 17, 2023 13:01
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.

Config JSON
3 participants