Go to Page... |
Compatibility: | Necrom (9.0.0) Scribes of Fate (8.3.5) Firesong (8.2.5) Lost Depths (8.1.5) High Isle (8.0.0) |
Updated: | 05/27/23 04:18 PM |
Created: | 11/11/20 02:08 PM |
Monthly downloads: | 4,603 |
Total downloads: | 86,091 |
Favorites: | 11 |
MD5: |
local AC_localization_strings = { de = { AC_IAKONI_TAG= "Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_1= "Set#1", AC_IAKONI_CATEGORY_SET_1_DESC= "#1 Set aus dem AddOn Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_2= "Set#2", AC_IAKONI_CATEGORY_SET_2_DESC= "#2 Set aus dem AddOn Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_3= "Set#3", AC_IAKONI_CATEGORY_SET_3_DESC= "#3 Set aus dem AddOn Iakoni's Gear Changer", }, en = { AC_IAKONI_TAG= "Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_1= "Set#1", AC_IAKONI_CATEGORY_SET_1_DESC= "#1 Set from Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_2= "Set#2", AC_IAKONI_CATEGORY_SET_2_DESC= "#2 Set from Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_3= "Set#3", AC_IAKONI_CATEGORY_SET_3_DESC= "#3 Set from Iakoni's Gear Changer", }, zh = { AC_IAKONI_TAG= "Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_1= "装备配置#1", AC_IAKONI_CATEGORY_SET_1_DESC= "#1 号装备配置 Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_2= "装备配置#2", AC_IAKONI_CATEGORY_SET_2_DESC= "#2 号装备配置 Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_3= "装备配置#3", AC_IAKONI_CATEGORY_SET_3_DESC= "#3 号装备配置 Iakoni's Gear Changer", }, }
Add strings to the string table for the client language (or the default language if the client language did not have strings defined for it). The localization_strings parameter is a table of language tables of localization strings, and the defaultLang parameter defaults to "en" if not provided.
With the example table defined above, you would call you initialization function:
LibLanguage.LoadLanguage(AC_localization_strings,"en")
AC_localization_strings["en"], AC_localization_strings["de"], and AC_localization_strings["zh"]
AC_localization_strings = AC_localization_strings or {} AC_localization_strings]["de"] = { AC_IAKONI_TAG= "Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_1= "Set#1", AC_IAKONI_CATEGORY_SET_1_DESC= "#1 Set aus dem AddOn Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_2= "Set#2", AC_IAKONI_CATEGORY_SET_2_DESC= "#2 Set aus dem AddOn Iakoni's Gear Changer", AC_IAKONI_CATEGORY_SET_3= "Set#3", AC_IAKONI_CATEGORY_SET_3_DESC= "#3 Set aus dem AddOn Iakoni's Gear Changer", }
Localisation\en.lua Localisation\$(language).lua
File Name |
Version |
Size |
Uploader |
Date |
35 |
6kB |
Shadowfen |
03/12/23 07:11 PM |
|
34 |
6kB |
Shadowfen |
06/05/22 05:30 PM |
|
33 |
6kB |
Shadowfen |
03/12/22 03:18 PM |
|
32 |
6kB |
Shadowfen |
11/04/21 09:04 PM |
|
31 |
53kB |
Shadowfen |
08/27/21 01:52 PM |
|
30 |
6kB |
Shadowfen |
04/30/21 01:51 PM |
|
29 |
6kB |
Shadowfen |
03/07/21 09:41 PM |
|
28 |
6kB |
Shadowfen |
11/11/20 02:08 PM |
![]() |
Comment Options |
![]() |
|
|
Thanks for the clarification.
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
Shadowfen |
View Public Profile |
Send a private message to Shadowfen |
Send email to Shadowfen |
Find More Posts by Shadowfen |
Add Shadowfen to Your Buddy List |
![]() |
|
|
Hi Shadowfen,
I do not seem to understand what this library is doing. What is different from the en.lua, de.lua, zh.lua files you'd normally use to define the localized texts + added to the txt manifest file, like your described it in this's lib's description too? Does LibLanguage.LoadLanguage(AC_localization_strings,"en") handle the creation of the string numbers you have added to your AC_localization_strings table, so that GetString is able to use these constants afterwards? Or is there any other benefit this lib provides?
Last edited by Baertram : 11/11/20 at 02:20 PM.
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |