Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overlays output wrong resource names #448

Open
RitikShah opened this issue Sep 1, 2024 · 1 comment · May be fixed by #455
Open

Overlays output wrong resource names #448

RitikShah opened this issue Sep 1, 2024 · 1 comment · May be fixed by #455

Comments

@RitikShah
Copy link
Member

When loading a pack with overlays in 1.21, the overlays will output older resource names (functions instead of function).

Notes

Likely a consequence of this code snippet:

beet/beet/library/base.py

Lines 823 to 826 in ba4a362

if "pack.mcmeta" in value.extra:
del value.extra["pack.mcmeta"]
if "pack.png" in value.extra:
del value.extra["pack.png"]

When 1.21+ support was added, we needed a way to know how to output the correct resource naming since importing would support both the old and the new. A source map was introduced to figure out the correct naming based on the pack format. Since overlay packs don't keep track of a pack format, it defaults to the wrong one.

Recommended Changes

  • Overlay packs should likely match the pack format that's listed in the overlays section of the pack.mcmeta file. This might be a range, so perhaps defaulting to the newest number in said range would be the best.
    • Inheriting the pack_format from the parent pack would likely end up with incorrect behavior as often you are writing overlays for older pack formats.
@BPR02
Copy link

BPR02 commented Nov 21, 2024

I think @misode has a fix for this. This branch is used by GM4 https://github.com/misode/beet/tree/fix-overlay-folders

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants