-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Region flag and game ID on game selection screen #12637
Conversation
The Region of a game disc is a separate property and doesn't always correspond with the Disc_ID property. A Korean flag is indeed necessary, and I would also add something for when it couldn't be determined because the emulator seems to guess it from the third character of Disc_ID, meaning it's not gonna be accurate. Line 262 in 6610cd7
|
Added korea region, both as flag and in game info. About detection accuracy it seem from this line |
It looks like there are at least 5 region types for PSP games: And each region has several different Game ID/UMD Serial codes. If a game has an un-identifiable region, why not leave it blank/without a region flag? |
PPSSPP detect the region (as shown on game info screen) by checking the 3rd letter of the code (notice how all the ID you listed have the same 3rd letter) as this: U - USA If the letter doesn't match any of those the region will be "other" and no region will be written on game info screen (and no flag will be displayed in this PR). |
There is already a method in the code for detecting the region based on specific ID's but it's commented out in favor of the 3rd-character detection. Line 270 in 6610cd7
However, I still don't believe this is going to be accurate. I see multiple region types for NPHH ID's in a database. Perhaps we should look into how UMDGen determines the region? |
NPHH will be detected as Hong kong, is that a possible region in UMDGen? |
If that's the reason then the base assumption was wrong to begin with: games can have multiple versions and rereleases for the same region. Take a loot at GTA Liberty City Stories which has:
A better method to tell the game version would be to use a combination of Disc_ID and Disc_Version. |
We've gotten a bit off-topic here, this PR is a nice addition for the users of the emulator. However, game region alone is not reliable for telling specific game versions apart. As for how PPSSPP determines the region should be discussed in a new issue. |
Added game ID and version (not sure if any game have different feature in different version in the same region tho', and that what i thought it was the main use case). Still both flag and ID are optional and disabled by default so I see no harm in having them. |
@iota97 you should probably avoid those features for Homebrew as we generate fake ID for them. Pretty much everything launched from "Game" folder might have a fake ID(althrough the detection is also checking some other things, it's overally recommended for compatibility to not place any commercial games inside that folder while always placing homebrew only there), we do assign them a "HOMEBREW" region if I recall, but there's also some still unsolved race issue where homebrew is not detected at recent screen on windows when using "" for path divider. Edit: or actually nvm, you're applying this only for < GAMEREGION_MAX and homebrew get's higher, it still might be affected by the bug I mentioned, but it's not the scope for this pr. |
I like the flag idea as long as we can get consensus on the region detection. Showing the game ID is maybe kinda odd but I guess sometimes useful. How does this look in list view? |
I have to say that does look a little too cluttered. I'd prefer Abbanon's approach, but I'm also fine with just leaving them out in list view for now, and tweak that look later. |
I like what you did with the icons in list view. Maybe we can display the game_id+version in smaller text size so it takes up less space. Could omit the brackets too that way. For the grid view, would it be possible to highlight the text with a semi-transparent color for the lighter icons? |
The only thing I could suggest further would be to shift the List View thumbnails to the right a tiny bit, so the gear and flag icons don't seem so squished into the edge. But that's just me being picky. |
Now we're getting somewhere :) I like it. By the way, I think it might be time to rewrite this stupid texture atlas system to avoid needing to generate a CPP file. I'm gonna file an issue on that. |
Add small 22x14 flags icon (found online under creative common license) based on game region if enabled in the setting (Asia region uses China flag).
Fixes #12636.
PS: Atlas file have been generated on Linux, it seem to have worked fine, but it might be better rebuild it on windows for extra safety?