Character encoding (Generation II): Difference between revisions

Adding additional prose, paralleling Character encoding (Generation I)
(→‎English: Add Unown Mode encoding)
(Adding additional prose, paralleling Character encoding (Generation I))
Line 1: Line 1:
{{incomplete|needs=French, German, Italian, and Spanish character encodings}}
{{incomplete|needs=Pokémon Stadium 2 encoding. Similar level of detail to English for non-English encodings.}}
The [[Generation II]] games use a proprietary '''character encoding''' to store text data. The Generation II encoding is largely similar to the [[Generation I]] {{OBP|character encoding|Generation I|encoding}}. Versions of the games in different languages may use different encodings, some more different than others.
In the [[Generation II]] [[core series]] games, a proprietary '''character encoding''' is used to store text data. Different languages use different encodings, although Western language games have very similar encodings to each other.
 
The Generation II encoding is largely similar to the [[Generation I]] [[Character encoding (Generation I)|encoding]].
 
==Compatibility==
The exact character encoding differs between languages, although all Western languages use almost-equivalent encodings. The set of [[Text entry (Generation II)|user-enterable characters]] in Trainer names and Pokémon [[nickname]]s is the same in all Western languages except German; in German, letters with umlauts are enterable (<code>ÄÖÜäöü</code>), but to compensate it is not possible to enter a semicolon and either a space{{sup/2|GS}} or multiplication sign{{sup/2|C}}.
 
In the Generation I and II games, the only supported cross-language compatibility is among the Western games. Attempting to trade or battle between a Western language game and a Japanese or Korean game will usually result in some kind of corruption in both games, and is completely disabled in the [[Virtual Console]] releases. Between Western language games, the only text that can be transferred is the player's name, the [[nickname]]s and [[Original Trainer]]s of their party Pokémon, and the contents of [[Mail]]. When reading Mail in a Western language game, the game uses the character encoding of the language the Mail was written in, rather than the current game's language, which prevents the text from being corrupted.
 
Due to the encodings of Western language games mostly being compatible, when [[trade|trading]] Pokémon between different Western languages, [[nickname]]s and [[Original Trainer]] names are usually displayed correctly, with the exception of characters with diacritics (specifically, some characters obtainable in names in the Spanish versions that cannot be [[Text entry (Generation II)|entered by players]]). The [[Original Trainer]] of Pokémon obtained in [[in-game trade]]s in Generation I is codepoint 0x5D, a control character that prints "TRAINER" in the game's language, meaning that it is automatically translated when traded between languages.
 
The [[Character encoding (Generation I)|Generation I character encoding]] for each language is almost the same as the Generation II encoding, with all characters that can be entered in Trainer names and Pokémon nicknames remaining at the same codepoints in both generations. However, the English Generation I games do not support letters with umlauts that can be entered in German games—simply displaying them as spaces—although the code points are preserved so they will be correctly displayed in other games. This means that trading Pokémon between Generation I and II games of the same language will not affect their nicknames or Original Trainer names.
 
===Poké Transporter===
{{main|Poké Transporter#Character transcoding|Poké Transporter → Character transcoding}}
When transferring a Pokémon from a Generation I or II game via [[Poké Transporter]], its nickname and Original Trainer need to be transcoded from this character encoding to that of [[Pokémon Bank]]. Due to differences in the characters that can be entered or otherwise appear in names in these games and the Generation VII games, some characters are not transcoded to the same characters they represent in these games.
 
Additionally, the name of Box 1 (the box that will be transferred) is displayed in Poké Transporter. The range of characters that can be entered in Box names is broader than in nicknames and Trainer names, and varies more between languages, but Poké Transporter still makes an effort to display Box names accurately.
 
==Rendering==
Due to how text is rendered in the Generation II core series games, all non-control characters take up the exact same amount of space (i.e. the games effectively use a {{wp|monospaced font}}). In Western languages, some ligature characters exist to display two characters within the width of one (e.g. the character <code>'s</code> is the same width as <code>s</code>).
 
These same code points are used for both rendering text and other elements. For example, code points 0x79-0x7E are {{wp|box-drawing character}}s used to draw the boundaries of text boxes; in certain user interfaces (e.g. in battles, on summary screens, and in the Pokédex) parts of the tileset overwrite code points that are not used to display text in that interface.
 
Some codepoints are used for different characters in different contexts. For example, 0x6E and 0x6F usually contain hiragana character leftover from the Japanese version, but when displaying the length of {{p|Magikarp}} at the [[Lake of Rage]] they are replaced by symbols for feet and inches instead (<code>′</code> and <code>″</code>).


==English==
==English==
Line 33: Line 57:
|-
|-
! 7-
! 7-
| <sup>P</sup><sub>O</sub> || <sup>K</sup><sub>é</sub> || “ || ” || ・ || … || ぁ || ぇ || ぉ || ╔ || ═ || ╗ || ║ || ╚ || ╝ || {{tt|␠|Space}}
| <sup>P</sup><sub>O</sub> || <sup>K</sup><sub>é</sub> ||style="background: #{{crystal color light}}"| “ ||style="background: #{{crystal color light}}"| ” || ・ || … || ぁ || ぇ || ぉ || ╔ || ═ || ╗ || ║ || ╚ || ╝ || {{tt|␠|Space}}
|-
|-
! 8-
! 8-
Line 64: Line 88:
{{Colorswatch|FFD|Control characters}}
{{Colorswatch|FFD|Control characters}}
{{Colorswatch|FDF|Special duplicate characters}}
{{Colorswatch|FDF|Special duplicate characters}}
{{Colorswatch|{{crystal color light}}|Exclusive to Pokémon Crystal}}
{{Colorswatch|{{crystal color light}}|Differs between Pokémon Gold and Silver and Pokémon Crystal}}


===Notes===
===Notes===
Line 72: Line 96:
** 0x60-0x62 are technically bold <code>'''A'''</code>, <code>'''B'''</code>, <code>'''C'''</code> in the base font, but are almost always immediately overwritten with the characters listed in the above table (<code>█</code>, <code>▲</code>, <code>[[File:Character 0x62 ii.png|16px|&#x1F581;]]</code>). Since these characters will almost never render as their base values, the superseding values are used in the table above.
** 0x60-0x62 are technically bold <code>'''A'''</code>, <code>'''B'''</code>, <code>'''C'''</code> in the base font, but are almost always immediately overwritten with the characters listed in the above table (<code>█</code>, <code>▲</code>, <code>[[File:Character 0x62 ii.png|16px|&#x1F581;]]</code>). Since these characters will almost never render as their base values, the superseding values are used in the table above.
* 0x6E-0x6F and 0x76-0x78 are Japanese [[wikipedia:hiragana|hiragana]] leftover in the character table from the Japanese version. They are not used in the English version.
* 0x6E-0x6F and 0x76-0x78 are Japanese [[wikipedia:hiragana|hiragana]] leftover in the character table from the Japanese version. They are not used in the English version.
* 0x72 and 0x73 are <code>『</code> and <code>』</code> in Pokémon Gold and Silver, and <code>“</code> and <code>”</code> in Pokémon Crystal.
* 0x74 is an [[wikipedia:interpunct|interpunct]] leftover from the Japanese version. It is not used in the English version.
* 0x74 is an [[wikipedia:interpunct|interpunct]] leftover from the Japanese version. It is not used in the English version.
* 0x79-0x7E are [[wikipedia:box-drawing characters|text box boundaries]]. The player can change how they display in the [[Options]] menu.
* 0x79-0x7E are [[wikipedia:box-drawing characters|text box boundaries]]. The player can change how they display in the [[Options]] menu.
Line 217: Line 242:


{| class="wikitable" style="text-align: center; border-collapse: collapse;" cellpadding="2px" width="375px"
{| class="wikitable" style="text-align: center; border-collapse: collapse;" cellpadding="2px" width="375px"
|- style="color: #000"
|-
! || -0 || -1 || -2 || -3 || -4 || -5 || -6 || -7 || -8 || -9 || -A || -B || -C || -D || -E || -F
! || -0 || -1 || -2 || -3 || -4 || -5 || -6 || -7 || -8 || -9 || -A || -B || -C || -D || -E || -F
|- style="background: #DDD"
|- style="background: #DDD"
Line 229: Line 254:
! 3-
! 3-
|style="background: #DDD"|  
|style="background: #DDD"|  
| &nbsp; ||style="color: red"| [[File:Character 0x32 ii Unown.png|█]] || [[File:Character 0x33 ii Unown.png|┌]] || [[File:Character 0x34 ii Unown.png|─]] || [[File:Character 0x35 ii Unown.png|┐]] || [[File:Character 0x36 ii Unown.png|│]] || [[File:Character 0x37 ii Unown.png|│]] || [[File:Character 0x38 ii Unown.png|└]] || [[File:Character 0x39 ii Unown.png|─]] || [[File:Character 0x3A ii Unown.png|┘]] || [[File:Character 0x3B ii Unown.png|&#x1FB34;]] || [[File:Character 0x3C ii Unown.png|&#x1FB38;]] || [[File:Character 0x3D ii Unown.png|◁]] || [[File:Character 0x3E ii Unown.png|▷]] || [[File:Character 0x3F ii Unown.png|△]]
| &nbsp; || [[File:Character 0x32 ii Unown.png|█]] || [[File:Character 0x33 ii Unown.png|┌]] || [[File:Character 0x34 ii Unown.png|─]] || [[File:Character 0x35 ii Unown.png|┐]] || [[File:Character 0x36 ii Unown.png|│]] || [[File:Character 0x37 ii Unown.png|│]] || [[File:Character 0x38 ii Unown.png|└]] || [[File:Character 0x39 ii Unown.png|─]] || [[File:Character 0x3A ii Unown.png|┘]] || [[File:Character 0x3B ii Unown.png|&#x1FB34;]] || [[File:Character 0x3C ii Unown.png|&#x1FB38;]] || [[File:Character 0x3D ii Unown.png|◁]] || [[File:Character 0x3E ii Unown.png|▷]] || [[File:Character 0x3F ii Unown.png|△]]
|-
|-
! 4-
! 4-
Line 270: Line 295:
{{Colorswatch|DDF|Same as default font}}
{{Colorswatch|DDF|Same as default font}}
{{Colorswatch|FFD|Control characters}}
{{Colorswatch|FFD|Control characters}}
{{Colorswatch|{{crystal color light}}|Exclusive to Pokémon Crystal}}
{{Colorswatch|{{crystal color light}}|Differs between Pokémon Gold and Silver and Pokémon Crystal}}


* 0x00-0x30 is the sprite buffer for the Unown's sprite (including the white padding), tiled top-to-bottom then left-to-right.
* 0x00-0x30 is the sprite buffer for the Unown's sprite (including the white padding), tiled top-to-bottom then left-to-right.