Skip to content

Add ability to detect MCP feature states #14

@NullCascade

Description

@NullCascade

I'd like to add this before 0.10 launches. The function should take a single argument, the ID of the feature, and return the state of the feature.

MCP keeps track of what features are enabled in ./mcpatch/installed. Starting at 0x3C in the file, it seems to contain a list of 32-bit integers. Each integer matches an ID in the describe.json. If the number is negative, the feature is disabled. If the number is positive, it is enabled.

Example usage:

long isFeatureEnabled
setx isFeatureEnabled to xIsCodePatchFeatureEnabled 14
ifx (isFeatureEnabled)
    MessageBox "User has feature #14 enabled. Item values increase with enchantment value."
endif

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions