MrCheeze / GYTB

Super simple custom badge homebrew for the 3DS home menu.
168 stars 15 forks source link

Adding new PNG files sometimes replaces placed badges with different ones #6

Open flarn2006 opened 8 years ago

flarn2006 commented 8 years ago

This seems to happen if a new PNG file is added that comes before already-existing files in alphabetical order. My guess is that badges are assigned an ID number, and files that come earlier in alphabetical order get a lower ID. But if you add a new file that comes earlier and run GYTB again, it shifts the later badges' ID's ahead without changing the data for already placed badges. As a result, the ID's of the placed badges no longer point to the badges they're supposed to be, so they show up as different ones.

To reproduce:

  1. Run GYTB to make sure all available official badges are dumped, and the badge list is up to date.
  2. Place some badges, custom or otherwise.
  3. Place a new PNG file in the badges folder, giving it a name that, in alphabetical order, comes before all other files.
  4. Run GYTB again.
  5. Restart the Home Menu. The fastest way to do this is to press Power, then when you get the screen telling you about Sleep mode, press Home.
  6. Look at the badges you placed. They will be different ones than they were before.

If this problem is in fact caused by what I'm thinking it is (which seems pretty likely) the best way to fix it would probably be by remembering which ID numbers were given to which badges. When a new file is added that it doesn't have a remembered ID number for, just give it the lowest one that isn't taken. It would also probably be a good idea to, whenever you run GYTB, have it scan its list for any remembered files that no longer exist (i.e. they have been deleted) and remove them from that list, to free up ID's.

elyckir commented 3 years ago

Did you ever find a solution for this?

les-citrons commented 2 years ago

this problem is quite annoying. it is sad that it still remains.

egscodes commented 1 year ago

There's 3 solutions you can do:

  1. Restart console and check what badges changed then manually fix
  2. Delete all badges and start over (will be pain if you have alot of them)
  3. Put a number infront of the filename then if you delete a picture replace it with another