Skip to content

game/mods/mod_manager: Add support for Launchpad's custom mod statuses. #9

@DaloLorn

Description

@DaloLorn

Some of the behaviors of the Launchpad's mod manager pane require new mod statuses to be present for disambiguation. Without them (or an external config file, which feels a little clunky), the Launchpad can't correctly process these scenarios:

  • A mod is implicitly enabled by a deriving mod. (Implied)
  • A mod is enabled, but is also implicitly enabled by a deriving mod. (EnabledDependency? Dunno, still figuring out the terminology here... and possibly even how the Launchpad should handle it in the first place.)

The Launchpad can safely write the relevant values to mods.txt. Per lines 349-350, any value other than "Forced" and "Enabled" is interpreted as "Disabled". However, any scripts calling saveState() at line 381 via the saveModState() global function (used by the ingame mod menu and the mod editor) will then overwrite those values with an actual "Disabled" value, which is not ideal.

This is a low-priority tweak, as it should hopefully only affect users who are using both the Launchpad and the ingame mod menu, and users which use the mod editor. Even then, it'll only have an impact in very specific contexts, and will only amount to a QoL inconvenience whenever it affects them at all.

  • Add storage for new Implied and EnabledDependency statuses.
  • Add proper serialization for those statuses.
  • Preferably expose those statuses to the script engine, so that the mod menu can be altered to account for them. (However, we shouldn't yet make any such alterations. We'd need to complete AngelScript compiler: Update to latest version, add support for OpenSR-only scripts. #10 first, for backwards compatibility with builds not featuring these statuses.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions