-
Notifications
You must be signed in to change notification settings - Fork 38
Fix PlayStation serial code region parsing #542
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
Conversation
Deterous
commented
Aug 30, 2023
- Do not assume S_J_ and S_P_ serials are Japanese
- Fix typo: PABX -> PBPX
- PCXC are Japanese
- PUBX are USA
- Do not assume S_J_ and S_P_ serials are Japanese - Fix typo: PABX -> PBPX - PCXC are Japanese - PUBX are USA
|
I've also just realised there are no PS2 S_J_ serials anyway, so that line is irrelevant. |
|
Please note that this is used by both PS1 and PS2. Don't remove things or change existing cases unnecessarily. |
|
I hope MPF does squash-merging.. sorry, not used to C# |
| switch (serial[3]) | ||
| { | ||
| case 'S': | ||
| // Check first two digits of S_PS serial | ||
| switch (serial.Substring(4, 2)) | ||
| { | ||
| case "46": return Region.SouthKorea; | ||
| case "56": return Region.SouthKorea; | ||
| case "51": return Region.Asia; | ||
| case "55": return Region.Asia; | ||
| default: return Region.Japan; | ||
| } | ||
| case 'M': | ||
| // Check first three digits of S_PM serial | ||
| switch (serial.Substring(4, 3)) | ||
| { | ||
| case "645": return Region.SouthKorea; | ||
| case "675": return Region.SouthKorea; | ||
| case "885": return Region.SouthKorea; | ||
| default: return Region.Japan; // Remaining S_PM serials may be Japan or Asia | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feels really difficult to keep up to date, I'll be honest. I understand that it's far more accurate, though.
mnadareski
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good with the changes in terms of preserving old functionality and refining errant things.