Jump to content

Translators needed! Very small project.


subtledoctor

Recommended Posts

My new armor system mod relies on matching certain terms to strings in the game - like, finding the word "dragon" in "Blue Dragon Plate." I've gotten it set up such that it can work in different languages... so now I need translations into other languages to that it can work for everyone!

 

I have a complete Polish translation of the mod. Doing more full translations would be a large undertaking. So in the meantime, I propose to only get translations of the small number of strings involved in the armor system, and I'll keep the rest of the strings in English for now. That way a player can at least successfully get the functional benefits of that component.

 

Here are the strings that need translation:

 

 

@10001  = ~^Armor Class:.+$~
@10002  = ~Armor Class: ~
@10003  = ~Damage Resistance: ~
@10004  = ~Dexterity Penalty: -~
@10005  = ~Arcane Casting Speed Penalty: +~
@10006  = ~Weapon Attack Speed Penalty: +~
@10011  = ~dragon~
@10012  = ~elven~
@10013  = ~elvish~
@10014  = ~sylvan~
@10015  = ~bladesinger~
@10018  = ~robe~
@10019  = ~cloak~
@10021  = ~Stealth, Pick Pockets: -~
@10022  = ~Open Locks, Set Traps: -~
@10023  = ~Find Traps, Detect Illusion: -~
@10030  = ~Armor of Faith

Level: 1
Sphere: Protection
Range: 0
Duration: 3 rounds + 1 round/level
Casting Time: 1
Area of Effect: The caster
Saving Throw: None

The caster of this spell receives significant protection against melee and magical attacks. This magical armor-like force surrounds the caster and absorbs a portion of any damage taken. This amounts to an effect 10% boost to damage resistance against all damage types.~

 

The terms should match those used in the game strings in each language. Like, the translation for "dragon" should match the word found in the name of the "Blue Dragon Plate" armor. Etc.

 

If anyone would like to help, reply in this thread or just PM me. Thanks!

Link to comment

@Gwendolyne thanks!

 

Btw if anyone wants to give me the translation of those three terms in languages that use other characters, like Russian, you can attach a text file with them, I think it has to be coded as utf-8 - the same as a tra file.

 

I now have French and Italian translations, and I'll see if etamin can update the Polish tra.

Link to comment

The following lines are from the various BG:EE dialog.tlk files:

EN:
Armor Class
Dragon
Elven

CH:
防御等级
龙
精灵 (not certain if it matches more than Elven Chain Mail)

CS:
Obranné číslo
Dračí / Drak
Elfí

DE:
Rüstungsklasse
Drache
Elfen

ES:
Clase de armadura
Dragón / Dragon
élfica

JP:
アーマークラス
ドラゴン / 竜
エルフ

KO:
방어도
드래곤
엘프제

RU:
Класс защиты
дракон (plus various suffixes)
Эльфийск (plus various suffixes)
Link to comment
@10012 = ~elven~

@10013 = ~elvish~

@10014 = ~sylvan~

@10015 = ~bladesinger~

@10018 = ~robe~

@10019 = ~cloak~

 

Btw I advise to merge things into ~[Ee]lven\|[Ee]lvish\|[ss]ylvan\|[bb]ladesinger~ form, rather than check them individually - it's entirely possible that other language may have 3 or 5 variations. They can certainly regexp one of the strrefs you use, but it may be not an obvious thing.

Link to comment

The following lines are from the various BG:EE dialog.tlk files:

EN:
Armor Class
Dragon
Elven

CH:
防御等级
龙
精灵 (not certain if it matches more than Elven Chain Mail)

CS:
Obranné číslo
Dračí / Drak
Elfí



ES:
Clase de armadura
Dragón / Dragon
élfica

JP:
アーマークラス
ドラゴン / 竜
エルフ

KO:
방어도
드래곤
엘프제

RU:
Класс защиты
дракон (plus various suffixes)
Эльфийск (plus various suffixes)

DE:

Rüstungsklasse (also possible Ruestungsklasse to avoid the ü)

Drache (this is the creature - in context of items you would use

Drachensomething, e.g. Drachenschuppen = drangon scales

Elfen (same here you would use Elfensomething e.g. Elfenkettenhemd = Elven Chain Mail

Link to comment

Okay NEXT question (hopefully the last for a while):

 

How does USING TRA work?

 

If I have only two translations of the mod, but I want to be able to capture those three terms ("armor class," "elven," "dragon") in any language - setting aside the regexp issues for the moment - can I read the game's installed language from the .ini/.lua file, and set a variable for the language being used by the player, and for those three references in the .tp2, use a tiny little .tra file that just has those three terms?

 

I've seen mods that have various different .tra files and have USING... in their .tp2, but I've never quite understood how that works.

Link to comment

According to http://www.weidu.org/~thebigg/README-WeiDU.html (taken from COMPILE description, which is one of several actions that can be followed by "USING traFile list" syntax):

 

First, this loads all of the traFiles presented. If any of their paths contain %s, the %s is replaced with the languageDirectory of from the Language the user selected. If you specified AUTO_TRA mymod/%s above, WeiDU will also attempt to load mymod/languageDirectory/sourceFile.tra for every sourceFile in the list.

Looking at the descriptions of other commands, WeiDU will forget the USING traFiles after this command (it loads and considers them only for this single action).

 

If you load several tra files that set values for the same string (e.g., first.tra has @20 = ~abc~, second.tra has @20 = ~def~), the last one wins.

 

Most mods that support multiple languages use a LANGUAGE block at the top of the mod to list the supported options, and based on the selection they then load a corresponding tra file. I'd recommend this method rather than trying to inspect game config files (lua/ini) and extract the user's current language. And if you use LANGUAGE to load the appropriate tra file earlier, you don't need to also use the USING traFiles syntax.

 

Example from SCS:

 

 

LANGUAGE
"English"
ENGLISH
 ~stratagems/tra/english/english.tra~
LANGUAGE
"Espanol (www.clandlan.net)"
SPANISH
 ~stratagems/tra/english/english.tra~
~stratagems/tra/spanish/spanish.tra~

LANGUAGE
"Polski (Yarpen)"
POLISH
 ~stratagems/tra/english/english.tra~
~stratagems/tra/polish/polish.tra~

LANGUAGE
"Deutsch (Leonardo Watson)"
GERMAN
 ~stratagems/tra/english/english.tra~
 ~stratagems/tra/german/german.tra~

LANGUAGE
"Francais (Mornagest/Isaya)"
FRENCH
 ~stratagems/tra/english/english.tra~
 ~stratagems/tra/french/french.tra~

 LANGUAGE
"Italiano (Stoneangel)"
ITALIAN
 ~stratagems/tra/english/english.tra~
 ~stratagems/tra/italian/italian.tra~

 LANGUAGE
"Russian (Prowler/Silent)"
RUSSIAN
 ~stratagems/tra/english/english.tra~
 ~stratagems/tra/russian/russian.tra~


 LANGUAGE
"Korean (Menocu)"
KOREAN
 ~stratagems/tra/english/english.tra~
 ~stratagems/tra/korean/korean.tra~

 

 

Note you can list multiple tra files under each language. Again, last one wins, so SCS basically defaults all strings to English and then overrides with translated strings (which might be a subset).

Link to comment

Subtledoctor, I don't know anything about modding, but maybe this would help: http://forums.pocketplane.net/index.php/topic,29583.msg338101.html#new

 

It seems I asked the same question. ;)

 

however, you can use this :

COMPILE ~%MOD_FOLDER%/Scripts/Sorts/GWFest1.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFest1A.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFest1B.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFest1C.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFest1D.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFestCh.baf~

        ~%MOD_FOLDER%/Scripts/Sorts/GWFest1Z.baf~    USING ~%MOD_FOLDER%/tra/%LANGUAGE%/GW_Cutscenes.tra~

OR

LOAD_TRA ~%MOD_FOLDER%/tra/%LANGUAGE%/GW_Items.tra~

 
COPY item.itm override SAY NAME1 @nnn ...

with @nnn = ~Dragon~

...

Link to comment

OUTER_SPRINT will happily accept @<string> references and replaced them with the last corresponding string loaded from tra files via any of LANGUAGE, AUTO_TRA, WITH_TRA or LOAD_TRA.

 

USING or WITH_TRA have the benefit of being temporary (USING only applies to the current action; WITH_TRA only applies to the code inside it). As Wisp's comment explained in the post Cahir linked, this means you can use the same @number for different strings in different parts of your code.

 

To me, using the same @number for different strings is actually a bit confusing for a reader, so I would prefer the global methods until you find yourself with a lot of strings (which I don't think is an issue for your tweak mod).

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...