# Preparation

**1. Create LanguageTypeCData**

Create a new LanguageTypeCData resource to define the language type that suits your project needs. Assets (or right-click menu in the Project) > Create > fuliu > Localization > LanguageType

Language name: Choose a name that represents the language type and that you can understand.

Language ID: is generated automatically, never change it.

Open or not: This attribute determines whether the language is open to the public. The player cannot choose which language is not open to the public.

System language: This property needs to select the correct value for the language type. Used to determine what type of language the system language corresponds to in MyLocalization.

Ali Cloud language: When calling the automatic translation API, you need to know which language corresponds to Ali Cloud API. Set this property can be the first project in the AliLanguageType resource file into the Ali cloud language this property association, you can use the drop-down menu to select a language, so you do not need to type input (typing input can also be, as long as the input is correct).

![截图.png](https://2393128398-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbpNvIT2FzQN3Mk0Zlv1E%2Fuploads%2FnUZC8DkRFqJcPUHIAG2A%2F0.png?alt=media)

Right-to-left: A type of language that is or is not right-to-left, such as Arabic, which is right-to-left.

Associated TMP font: This property determines the default font to be used when TextMeshPro UI displays text in this language.

(this property only after import and open TextMeshPro will appear, in ProjectSettings. Player. Add Using\_TextMeshPro ScriptDefineSymbols said enabled TextMeshPro.)

Associated font: This property determines the default font used when Ugui text displays text in this language.

![截图.png](https://2393128398-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbpNvIT2FzQN3Mk0Zlv1E%2Fuploads%2FEyoDti4W0HQoOQ9eMrXi%2F1.png?alt=media)

**2. Create LocalizationSetting**

Add a gameobject named LocalizationSetting to the current scene, Hang the LocalizationSetting component, and set the LanguageTypeCData resource created in the previous step to the LocalizationSetting component languageType property.

Keep the default and current language values.

![截图.png](https://2393128398-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbpNvIT2FzQN3Mk0Zlv1E%2Fuploads%2F7Mi57HtY6LaDR6b0ejw2%2F2.png?alt=media)

The MyStringPack component is automatically mounted to handle localized text in code or used in tables such as Excel.
