Skip to content

Fix booster pack localization defaults#35

Open
DarkAutumn2618 wants to merge 1 commit into
Eremel:mainfrom
DarkAutumn2618:fix-booster-localization
Open

Fix booster pack localization defaults#35
DarkAutumn2618 wants to merge 1 commit into
Eremel:mainfrom
DarkAutumn2618:fix-booster-localization

Conversation

@DarkAutumn2618

Copy link
Copy Markdown

The Issue

When having an AltTexture that changes the localization text of a Booster pack, enabling then disabling the texture does not revert the text back to normal.

Example:

AltTexture({
    key = "boosters",
    set = "Booster",
    path = "boosters.png",
    keys = {
        "p_arcana_normal_1", "p_arcana_normal_2", "p_arcana_normal_3", "p_arcana_normal_4",
    },
    loc_txt = { name = "Boosters" },
    localization = {
        p_arcana_normal = {
            name = "TEST Arcana",
            text = { "TEST TEXT Arcana" },
        },
    },
})

The issue can be reproduced by:

  • Using this test mod: balatro-testmalverk-booster.zip
  • Applying the texture
  • Looking at the Arcana Packs in the collection screen
  • Removing the texture
  • Looking at the Arcana Packs again and seeing that the name is still the modified one

The Fix

The issue is caused by the default localization text not being saved properly for Boosters in Malverk.set_defaults. The fix is done by mirrorring the logic for Booster pack localization in the other functions, like at line 132.

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.

1 participant