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

Korean DS/3DS games use halfwidth gender symbols #4174

Closed
abcboy101 opened this issue Jan 27, 2024 · 1 comment
Closed

Korean DS/3DS games use halfwidth gender symbols #4174

abcboy101 opened this issue Jan 27, 2024 · 1 comment
Labels

Comments

@abcboy101
Copy link
Contributor

Describe the bug
From D/P/Pt to US/UM, the gender symbols that can be entered in Korean games are the halfwidth glyphs (0x01BB 0x01BC in Gen4, \u246D \u246E in Gen5, \uE08E \uE08F in Gen 6/7), not the fullwidth glyphs used in Japanese/Chinese games (0x00EE 0x00EF in Gen4, in Gen 5/6/7). Currently, the UnSanitizeChar methods do not properly handle this.

For Nidoran♀ and Nidoran♂, their Korean species names use the fullwidth glyphs in D/P/Pt and the halfwidth glyphs from HG/SS onward. The fullwidth glyphs are preserved when transferred to Gen5. I'm not able to test this myself, but the VC Korean Gen2 table appears to use the fullwidth glyphs, so an unnicknamed Nidoran transferred from Korean G/S might have its name treated as a nickname. Gen5->Transporter and Bank->HOME should reset their species names for unnicknamed Pokémon.

Relatedly, the editor incorrectly uses the halfwidth forms in Japanese for Gen4/5.

To Reproduce
Example 1:

  1. Hatch an unnicknamed Nidoran in a Korean Gen6/7 game
  2. View the Nidoran and use "Save PKM..."
  3. Open both files in a hex editor
  4. The saved PKM will incorrectly have fullwidth forms (U+2642/0)

Example 2:

  1. Hatch an unnicknamed Nidoran in Korean D/P/Pt
  2. Transfer to Korean Gen5
  3. View the Nidoran and use "Save PKM..."
  4. Open both files in a hex editor
  5. The saved PKM will incorrectly have halfwidth forms (U+246D/E)

Example 3:

  1. Nickname a Pokémon using gender symbols in Japanese Gen4/5
  2. View the Pokémon and use "Save PKM..."
  3. Open both files in a hex editor
  4. The saved PKM will incorrectly have halfwidth forms

Expected behavior
These can be verified by using drag-and-drop to save the Pokémon directly to a file, without going through the editor.

  1. The saved PKM should have halfwidth forms (U+E08E/F)
  2. The saved PKM should have fullwidth forms (U+2642/0)
  3. The saved PKM should have fullwidth forms

Additional context
GetIsFullWidthString doesn't appear to be used for Gen4/5 unsanitization. These halfwidth characters can be entered in Gen4-7 that aren't in the U+0000-0FFF or U+E000-EFFF ranges: , , , , , and (beside the Korean characters). For the edge case where the nickname/OT is a single glyph, it could be recognized as halfwidth even when the OT/nickname is unambiguously fullwidth, which wouldn't normally be possible.

@abcboy101 abcboy101 added the bug label Jan 27, 2024
@kwsch kwsch closed this as completed in 08ed482 May 12, 2024
@kwsch
Copy link
Owner

kwsch commented May 12, 2024

Looks like there are additional revisions for 7->8+ where symbols are migrated from the private section (0xE08x) back to the fullwidth section (0x24xx), and some that just get skipped (shortening the string). Maybe next time :P

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

No branches or pull requests

2 participants