[Bug]: Pack banners with uppercase file extensions are not loaded
niet-dev opened this issue · 2 comments
Is there an existing issue for this?
- I have searched the existing issues
Contact Details
Reply to the issue, or Discord: nietscape
Version Info
Latest available release
What operating system are you seeing the problem on?
Windows
Bug Behavior
If a pack banner has an uppercase file extension, the banner is not loaded. This is uncommon, but true for some packs that are downloaded in-game.
Expected Behavior
The banner should be displayed as if it had a lowercase file extension.
Reproduction Steps
- Open the game
- Download a pack like NBJS2 or midare megapack 5
- Notice the pack banner does not appear
- Go to the pack directory, change the file extension to lowercase (bn.PNG > bn.png, bn.JPG > bn.jpg)
- Restart etterna, pack banner appears
Anything else?
This is only true of pack banners. Chart banners with uppercase file extensions are loaded just fine (see Blockbuster, Comsten from NBJS2).
a really fast way to try to fix it is by modifying this
etterna/src/RageUtil/Utils/RageUtil.cpp
Lines 1000 to 1012 in 9a0b9fb
but it is also possible that filesystems care too much about case sensitivity for that to work. we can instead change the logic here to make it more general
etterna/src/Etterna/Actor/Base/ActorUtil.cpp
Lines 499 to 586 in 9a0b9fb