Skip to content

Do not hard code the values dependency constants #3

Open

Description

@szapp

The assumption that the dependencies would always have the same values seems to fail for heavily modified projects.

Use the variable-overwrite trick (see bottom of linked file) and an initialization function to check the type of the symbols to assess whether they have been defined as constants before. If not, check the type of the symbol and set their content to the expected value.

Whether this is possible for the focus instances has to be researched: If an existing instance is re-defined as variable, what happens.

Activity

  1. N1kX94 commented on Apr 28, 2025

    @N1kX94

    I'll add that declaring a variable is to blame
    const int GIL_SEPERATOR_HUM = 16; // Is fixed by the program

    The modifications based on the Returning 1.0 and itc. base all have a shifted separator and replacing it with a vanilla number breaks the "new guilds"

    I temporarily commented out this variable for myself so that it would work in some modifications, example guilds 1.6

  2. szapp commented on Apr 28, 2025

    @szapp
    OwnerAuthor

    @N1kX94 Thanks for that crucial insight! I should then add logic to infer that value at runtime instead like I do with some other constants.

    Good to hear that this solves the issue for you locally. Please refrain from distributing it, to avoid diverging versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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