When using numeric Parameters, the term's translation can be changed depending on the value of that parameter.

Some languages like English and Spanish, allow two plural forms (Singular and Plural). While others have up to 6 forms (Arabic has: Zero, One, Two, Few, Many, Plural).


The rules for each language selects the correct plural form based on the parameter number. This way, when the parameter value is 4, English selects the PLURAL form, but Russian selects the FEW form (which covers numbers ending in 2,3 or 4 as far as the second digit is not 1 (e.g. not 112, 313, 714, etc).


The complete set of rules for each language can be found here:

       UNICODE Language Plural Rules


I2 Localization implements all of this rules and selects the correct form depending on the parameter's value and current Language.


Example Scene: Assets\I2\Localization\Examples\Scenes\I2Localization    features Plurals.unity

Setup


To add a Plural variant to a translation, first you need to type a translation that contains at least one parameter. (e.g. "You have {[POINTS]} points").

As soon as you add the {[POINTS}] parameter to the text, an arrow will show in front of the the translation, that specifies that translation can have Plural variants.


Clicking the arrow for each language, will show ALL the valid plurals for that Language.



By default variants that are not filled, will fall-back to the PLURAL form.


Spreadsheet format


When exported to a CSV file or a Google Spreadsheet, translations with Plurals are encoded using tags to separate the different plural forms:

The supported tags are [i2p_Plural], [i2p_Zero], [i2p_One], [i2p_Two], [i2p_Few] and [i2p_Many].

The first tag is always [i2p_Plural] and for clarity can be omitted:


example with tags highlighted:  "You have {[POINTS]] poiints[i2p_Zero]You have no points[I2p_One]You have 1 point"

Created with the Personal Edition of HelpNDoc: Easily create PDF Help documents