game localization in python
DESCRIPTION
A story about bad game localization, and how we use Python to improve our productivity.TRANSCRIPT
![Page 1: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/1.jpg)
Walter Liu
2013/05/17
GAME LOCALIZATION BY
PYTHON
![Page 2: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/2.jpg)
Isn’t game localization
EASY?
Why not use UNICODE?
![Page 3: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/3.jpg)
My name is not <FullName>.
遊戲翻譯-踢牙老奶奶
Every sentence is 踢牙老奶奶.
![Page 4: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/4.jpg)
EPIC FAIL!!!
Flow & Tools
Summary
AGENDA
![Page 5: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/5.jpg)
EPIC FAIL !!!
![Page 6: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/6.jpg)
One Day ….
![Page 7: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/7.jpg)
Chinese > 300,0000 words
English > 500,000 words
1 expansion += 80,000 words
> 50,000 Lines
![Page 8: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/8.jpg)
1003 匕首
1004 長劍
1005 皮甲
1006 木盾
1003 Dagger
1004
1006 木盾
WHAT DID WE FAIL IN OUR TEXT FILES
![Page 9: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/9.jpg)
<data>xx</data>
<資料>xx</資料>
<data
>叉叉</data>
<data>叉叉/data>
WHAT DID WE FAIL IN OUR XML FILES
![Page 10: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/10.jpg)
tell($uid, “請往東邊走”)
tell($uid“Please go east.”)
tell($uid,“Please go east.
”)
WHAT DID WE FAIL IN OUR SCRIPT FILES
![Page 11: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/11.jpg)
printf(“%s撿起%d金幣”, uid, gold);
printf(“%d gold is picked up by %s.”, uid, gold);
printf(“%d gold is picked up by .”, uid, gold);
WHAT WE FAILED IN PROGRAM
![Page 12: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/12.jpg)
NPC/Spell name
in DB: 馬超
In data: 馬超
NPC/Spell name
in DB: Ma cao
In data: Ma Chao
WHAT WE FAILED IN ACROSS FILES
![Page 13: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/13.jpg)
> 1500 bugs
> 9 months
1 EXPANSION
![Page 14: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/14.jpg)
FLOW & TOOLS
![Page 15: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/15.jpg)
WHY DO PYTHON GOOD AT THIS?
Good Unicode library
Fast string process
Easy to develop
Excellent string library
![Page 16: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/16.jpg)
EXTRACT
new Original Text
old Original Text
old Translated Text
Delta Text for
translation
extraction bad log
extract.py
![Page 17: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/17.jpg)
EXTRACT EXAMPLE
ORIG-old ORIG-new TRANS-old TRANS-delta
1003 匕首 1003 匕首 1003 Dagger
1004 長劍 1004 長劍 1004長劍
1005 皮甲 1005 皮甲
Extract log
ID 1004 not existed in old translation article.
![Page 18: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/18.jpg)
MERGE/VERIFICATION
Last Translated Text
Delta Text for
translation
New translated textDelta Translated
Text
Out source translation
verification bad log
merge.py
(merge/verification)
![Page 19: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/19.jpg)
VERIFICATION LOG EXAMPLE
1003 匕首
1004 長劍
1005 皮甲
1006 木盾
1003 Dagger
1004
1006 木盾
Text ID 1004 is empty.
Text ID 1005 is missing.
Text ID 1006 didn’t translated.
![Page 20: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/20.jpg)
Data Preparation
Extract text
Summarize
Out sourcing
BEFORE Our sourcing
![Page 21: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/21.jpg)
Artist modify UI Use Merge toolUse a script of
Emeditor To importDB ImportDirectly useDirectly use
NPC data in DBscriptdataXmlTranslated UI
stringsini
Data importerXml importer Script importer SQL importerIni importer
Receive translation
files
Summarize name
table (Manual)
Data checker Script checkerName synchronizer
Upload to SVN 03
Test and fix
Upload to SVN 04
AFTER Our sourcing
Translated Text
Check Text format
Import/merge
Completed/Test
![Page 22: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/22.jpg)
RESULT
2000 => 200bugs
9 => 3 months
1 EXPANSION
![Page 23: Game Localization in Python](https://reader034.vdocuments.mx/reader034/viewer/2022042623/54b700ba4a79590a338b465b/html5/thumbnails/23.jpg)
Design your game I18N well.
Use/write tools to localize your game.
Python is a good tool for this.
Design a good localization flow to help
your team.
SUMMARY