Skip to content

Releases: GodotModding/godot-mod-loader

Godot 4.x - v7.0.1

11 Jun 17:46
e75c045
Compare
Choose a tag to compare

Godot 4.x - Major release v7.0.1

This release marks a significant milestone, as it signifies more than two years of effort to support Godot 4! Below, you will find installation instructions and a detailed overview of all merged pull requests that followed.

This release is compatible with Godot versions 4.1 through 4.3. Moving forward, we plan to provide dedicated releases for each Godot feature update. This will help reduce the need for backward compatibility trade-offs and allow us to better support each version.

Installation

Note

This release is targeted towards integration! We're actively working on improving the self-setup process,
and we are grateful for anyone willing to test the current version. Your help means a lot to us!

Godot Project Setup
Mod Loader Self Setup

Addressing class_name With Hooks

The most glaring issue of the 4.x ModLoader is extending a file using a class_name statement. For more info, see: #315. As a workaround, we introduce hooks—with major thanks to everyone who contributed to resolving this long-standing issue. See the fantastic PR by @KANAjetzt, @Qubus0, and @pirey0 in #408.

🚨 Breaking Changes

  • Removal of append_node_in_scene and save_scene for refresh_scene and extend_scene by @KANAjetzt in #378
  • steam_workshop_enabled has been replaced by load_from_steam_workshop by @KANAjetzt in #399
  • The MOD_CONFIG_DIR_PATH has been changed from user://configs to user://mod_configs by @KANAjetzt in #480
  • ModLoaderModManager has been entirely removed by @KANAjetzt in #540

Key PRs

Enhancements

  • feat: Allow both workshop and local mods to be loaded by @cgytrus in #369
  • feat: ✨ added refresh_config_data() and refresh_current_configs() by @KANAjetzt in #374
  • feat: ✨ add has_current_config() and has_config() by @KANAjetzt in #375
  • feat: script extensions sorter checks load order by @KANAjetzt in #382
  • feat: ✨ store the mod source in ModData by @KANAjetzt in #387
  • feat: ✨ added steam_id to ml_options by @KANAjetzt in #388
  • feat: ✨ added steam_workshop_id to ModManifest by @KANAjetzt in #393
  • feat: ✨ added is_mod_active to ModLoaderMod by @KANAjetzt in #398
  • refactor: ♻️ log the prefix on errors by @KANAjetzt in #400
  • refactor: use truthy values in dictionaries used as hashsets by @Qubus0 in #422
  • refactor: don't inline is_func_moddable by @Qubus0 in #423
  • refactor: ♻️ updated hook_pre_processor reference by @KANAjetzt in #424
  • style: 🔥 removed % from hook template string by @KANAjetzt in #428
  • feat: disable hook check when not needed by @Qubus0 in #429
  • feat: split off verbose hook preprocessing by @Qubus0 in #430
  • test: add new gut test cases for the hook preprocessor by @Qubus0 in #432
  • style: ✏️ Changed MOD_LOADER_HOOKS_START_STRING by @KANAjetzt in #433
  • feat: ✨ param and return manipulation for mod hooks by @Qubus0 in #436
  • feat: ✨ allow installing hooks from a file like extensions by @Qubus0 in #440
  • feat: ✨ param and return manipulation for mod hooks by @KANAjetzt in #469 (fixes merge of #440)
  • fix: 🚑 remove whitespace after _ModLoaderHooks.call_hooks by @KANAjetzt in #474
  • feat: ✨ detect and handle hooks for async methods by @Qubus0 in #475
  • test: 🧪 added tests for .process_script() by @KANAjetzt in #476
  • refactor: ♻️ use ModLoaderOptionsProfile instead of Dictionary by @KANAjetzt in #532
  • refactor: use GDRE for self setup by @KANAjetzt in #533
  • feat: per method hooks by @Qubus0 in #534
  • feat: ✨ options for game version validation by @KANAjetzt in #536
  • feat: new editor-only log type for dev hints by @Qubus0 in #538
  • feat: ✨ added load_from_unpacked option by @KANAjetzt in #541

Bug Fixes

New Contributors (to the 4.x branch)

Full Changelog: v6.0.2...v7.0.1

Godot 3.x - v6.3.0

27 Jan 11:26
92cd37b
Compare
Choose a tag to compare

v6.2.0 - Godot 3.5+

14 Jul 09:00
19a7b7f
Compare
Choose a tag to compare

Minor Release v6.2.0

In this update, we introduce a new feature for game developers to set Mod Loader options in a more flexible way. The new option system allows for configurations based on feature flags, enabling different settings for the mod loader depending on the context, such as the editor or published game builds.

Pull Requests

New Features

  • feat: add dictionary for overrides based on feature tags to options by @Qubus0 in #326

Refactors

Full Changelog: v6.1.0...v6.2.0

v6.1.0

04 Jul 07:08
352da65
Compare
Choose a tag to compare

Minor Release v6.1.0

This update addresses a performance issue related to the new script extension sorting introduced in v6.0.0. It also includes a refactor of the mod_main.gd initialization to no longer require the modLoader parameter in the _init() function.

🚨 Breaking Changes

Please note that this update may break mods that still rely on the modLoader argument in their _init() function. To mitigate this, a fallback and deprecation warning has been implemented that passes self as an argument if any arguments are detected in the mod_main.gd _init() function.

Pull Requests

New Features

Refactors

  • refactor: Remove self argument on mod_main.gd _init by @otDan in #324

Chores

Other Changes

Full Changelog: v6.0.2...v6.1.0

v6.0.2

01 Jul 09:19
26bcc8d
Compare
Choose a tag to compare

Patch v6.0.2

This patch addresses an issues related to the new user profiles introduced in v6.0.0. It also includes an update for the manifest validation.

See the Patch Notes v6.0.0 for a full list of changes made with the latest major update.

🚨 Breaking Changes

Additionally to the breaking changes listed for v6.0.0

It may break mods that have the same mod_id listed in both optional_dependencies and dependencies or load_before and incompatibilities. However, since the optional_dependencies and load_before feature was introduced in v6.0.0, it is highly unlikely that such conflicts exist.

Pull Requests

Bug Fixes

  • fix: 🐛 ModData init and uninstall detection by @KANAjetzt in #307

Validation

  • refactor: ♻️ unique ids optional_dependencies - dependencies by @KANAjetzt in #308
  • refactor: ♻️ unique ids load_before - incompatibilities by @KANAjetzt in #312

Other Changes

Full Changelog: v6.0.1...v6.0.2

v6.0.1

28 Jun 08:28
279a012
Compare
Choose a tag to compare

Patch v6.0.1

This patch addresses several critical issues related to the new user profiles introduced in v6.0.0. It also includes a deprecation warning fix, small code style improvements, and an improved README for the ModLoader repository.

See the Patch Notes v6.0.0 for a full list of changes made with the latest major update.

🚨 Breaking Changes

Additionally to the breaking changes listed for v6.0.0

Mods are now always unpacked and loaded into ModLoaderStore.mod_data. This change can potentially break Mod Lists that rely on having only loaded mods in mod_data. Consequently, these Mod Lists may display mods that are currently not loaded. To address this issue, authors of Mod Lists need to adapt their code to check the new is_active flag.

Pull Requests

Bug Fixes

  • 🐛 added missing static (#291) (0434f74)
  • 🐛 current_user_profile reference to user_profiles (#293) (3228cb2)
  • 🐛 check if mod zip is structured correctly (#303) (8327385)
  • 🐛 Fix ModLoaderUtils log deprecation using ModLoader.* (#300) (54018b2)

Refactors

  • ♻️ reworked disabling mods via user profile (#297) (21dea2a)
  • ♻️ reworked mod uninstall detection (#298) (ee7312a)
  • ♻️ lowered the log level from fatal to error (#304) (4bad0c1)

Style

Other Changes

  • ⬆️ update version const for v6.0.1 (#305) (9abd5c8)
  • 📝 updated readme with more details (#284) (97de024)

6.0.0 - Major New Features & Breaking Reworks

19 Jun 16:16
1683759
Compare
Choose a tag to compare

Major New Features

Most notable features of this release:

Steam Workshop Support

  • ModLoader now has native support for Steam Workshop!
    • Special thanks to Blobfish, the developer of Brotato, for layout the groundwork for workshop support.
    • Game developers might also like to try Blobfish's mod uploader, Godot Workshop Utility, which was recently updated to support tags.
  • More info: #148

New Config System

  • Every mod now has its own config JSON file, with a robust system behind the scenes that allows for precise data validation.
  • There are lots of new methods for interacting with a mod's configs, enabling modders to create powerful GUIs to alter and save them.
  • More info: #237

User Mod Profiles

  • User profiles let you decide which mods you want active, letting you swap between different sets of mods as needed.
  • More info: #214

Runtime Mod Disabling

  • You can now enable or disable mods while running a game!
  • This was one of the most requested features, and we're delighted to now support it!
  • More info: #203

Inheritance Checks for Script Extensions

  • Installing a script extension now follows the parent/child hierarchy correctly, which fixes a roadblock many mods have faced.
  • You might never notice this, but it's a much-needed improvement that allows modders to edit a lot more scripts.
  • More info: #124, #277

ModLoader Options

  • A new panel in the editor lets you tweak lots of settings, to help you develop mods faster and easier. Notable options include:
    • Enable/disable all mods.
    • Disable certain mods (this lets you keep all your mods in a single project, without them interfering with each other).
    • Change the log level to be more or less verbose.
    • Override the paths to your mods.
  • To edit them, open res://addons/mod_loader/options. From here, you can open options.tres in the Inspector, then click the resource name in the "Current Options" setting to expand it and edit the options.
  • These options also support multiple profiles, by dragging and dropping a profile resource file into the Current Options. Some examples are provided in the profiles directory.
  • More info: #145, #160

Logging Changes

  • Logs are now stored in memory, and have lots of new API methods via the new ModLoaderLog class.
  • This grants support for modders and developers to do things like creating terminals that display logged messages in-game, with the option to filter by log type (debug, success, info, warning, error).
  • More info: #205

Known Issues

  • When switching from a profile where a mod is inactive to a profile where the same mod is active, the active state of all other profiles is automatically set to active as well.

Breaking Changes

We've refactored the code to be easier to use, more robust, and give better indications of what's available for public use (everything in the api directory) vs. what parts are strictly internal (everything else, plus any classes or methods that start with an underscore (_).

In v6 we've also added new methods for deprecation (#156). This keeps existing mods working, but also provides a warnings if you're using an outdated method, with the warning telling you exactly which method to use instead.

View the Breaking Changes page on the wiki for more details on the changes needed in your mods.

Pull Requests

New Features

Bug Fixes

  • #134 - (3c19fddf) 🐛 Validation: Don't allow mods to include themselves as dependencies or incompatibilities
  • #168 - (6f9068b8) ✏️ Fix typo hypen -> hyphen
  • #176 - (8f669f09) ✏️ Fix typo: improt -> import
  • #183 - (40ae4f18) 🐛 Circular dependency check
  • #184 - (93e6cab4) 🐛 Continue check if circular dep is detected
  • #201 - (41b1801c) 🐛 Self setup chicken and egg problem
  • #202 - (80fea721) 🐛 Check for min length 3 in namespace and name
  • #215 - (34bcb833) 🐛 Check if a mod is_loadable
  • #234 - (a8b22394) 🐛 Wrong UNPACKED_DIR reference
  • #235 - (97eda11f) 🐛 Fix wrong function call
  • #276 - (8f030b2) 🐛 Always use warnings for deprecations in standalone builds
  • #276 - (286f296) 🐛 Transitive Comparator for script sorting
  • #278 - (90334fc) 🐛 log stack only saved for logged_messages.all
    ...
Read more

v5.0.1

24 Feb 14:20
b372e77
Compare
Choose a tag to compare

Features

Major

  • ModLoader can now be automatically installed (see #75 and #89, and #8 for more context)
  • Overwrites have a dedicated file, overwrites.gd (see #14 and #74)

Minor

  • Code style overhaul: The code is now cleaner and easier to read, and follows Godot's style guide
  • The mods.log file is now handled similarly to godot.log, with new versions being created and removed as needed (see #100)
  • Lots of validation improvements

Breaking Changes

New validation may make existing mods invalid:

  • #71 - Disallow leading zeros and overly long versions
  • #91 - Mod IDs listed in a mod manifest's dependencies and incompatibilities are now validated

Full Change List

Full Changelog: v4.1.0...v5.0.1

v4.1.0 - Fixes and minor improvements

23 Jan 23:15
8add151
Compare
Choose a tag to compare

Includes a few fixes and small improvements to the code. Major work is now being done on the develop branch, so this might be the last major release for a little while, aside from potential bugfixes.

What's Changed

  • Add counts for debug purposes by @otDan in #65
  • smaller fixes for utils json as dict by @Qubus0 in #66
  • add command line arg to ignore specific log names by @Qubus0 in #67
  • fix validating mod dir name by @Qubus0 in #68
  • fix log-ignore flag by @Qubus0 in #70

Full Changelog: v4.0.0...v4.1.0

v4.0.0 - Major Refactor

20 Jan 06:34
e67c7f7
Compare
Choose a tag to compare

ModLoader has been refactored by @Qubus0. See PRs ##60, #62, and #63 for details.

Refactor

The refactor has split the old single file of mod_loader.gd into 4 files:

Filename Description
mod_loader Same as before: The main entry point that sets up mods.
Loads mod data to the virtual filesystem, loops over them, and initialises them.
mod_data Stores and validates all Data required to load a mod successfully.
If some of the data is invalid, [member is_loadable] will be false.
mod_manifest Stores and validates contents of the manifest (ie. Author-ModName/manifest.json).
mod_loader_utils All utility funcs have been moved to here, including logging and getting CLI args.

Breaking Changes

  • ModLoader has been moved to the res://addons/ directory.
    • The new location is autoloaded in the same way the old one was, with the same file (mod_loader.gd).
    • Nothing else needs to change in your autoloads. There are other new classes, but they'll be loaded automatically.
  • Logging in mods is now handled via the ModLoaderUtils class, which provides a host of new logging options. The following changes will be needed in your mods:
    • ModLoader.mod_log -> ModLoaderUtils.log_info
    • ModLoader.dev_log -> ModLoaderUtils.log_debug
  • See also: Breaking changes from v3.1.0

What's Changed

Full Changelog: v3.1.0...v4.0.0