0 votes

I was implementing localization with .csv file in my game and everything was working fine inside the editor. But after I exported the game and opened the .exe file the localization won`t work anymore, only showing BTN_NEWGAME instead of NEW GAME for example.

A weird thing that occured too is that the .exe file works without any problems inside the game folder, but when I move to another folder the localization stops working. I also tried looking for errors on the debug log, but I found no errors.

Does anyone have any idea of what is happening? Am I missing something?

Here is the .csv file:
id,en,ptBR
BTN
NEWGAME,NEW GAME,NOVO JOGO
BTNLOADGAME,LOAD,CONTINUAR
BTN
EXTRA,EXTRA,EXTRA
BTNSETTINGS,SETTINGS,CONFIGURACOES
BTN
EXIT,EXIT,SAIR
BTNSTORY,STORY,HISTORIA
BTN
1PLAYER,1 PLAYER,1 JOGADOR
BTN2PLAYERS,2 PLAYERS,2 JOGADORES
BTN
RETURN,RETURN,VOLTAR
BTNTIMEATTACK,TIME ATTACK,L. DE TEMPO
BTN
HIGHSCORE,HIGHSCORE,RANKING
BTNCREDITS,CREDITS,CREDITOS
LAB
RESOLUTION,RESOLUTION,RESOLUÇÃO
LABFULLSCREEN,FULLSCREEN,TELA CHEIA
LAB
COLOR,COLOR,COR
BTNCONFIRM,CONFIRM,CONGIRMA
BTN
OK,OK,OK
LABBGM,BGM,BGM
LAB
SFX,SFX,SFX
LABKEYBOARDP1P,KEYBOARDP1,TECLADO P1
LAB
UP,UP,CIMA

in Engine by (18 points)

As far as I know, the CSV-File is converted by Godot to multiple translation.(countrycode).translation files. You should find these in the same folder than the csv file.

My impression is that these translation files didn't weren't packaged into the .pck file. Maybe you excluded them by some exclusion filter in the windows export settings? (ressources tab)

1 Answer

0 votes

Yes, the .translation files were generated and I added them on the Localization tab. I too have the impression that they weren't packaged, but I can't find the cause. I even tried adding the *.pck files on the resource tab, but it didn't work

by (18 points)

Your .CSV file seems to be wrong written for me. I usually write each language in separate files (e.g. en.csv, pt.csv). Try splitting your language file and load each one in the language tab.

I tried creating separate files as you suggested but sadly it didn`t work. I will try creating a new project and see if the problem is some configuration inside my game or not. I recompiled godot to use godotSteam, but I don't think recompiling would cause any problems with localization

Test the official Godot build and check if the problem persists.

Check if you didn't selected export all resources in the project in the export settings.

Hello, sorry for the late reply. Everything is chaotic with the release date of the game so close. I tested again and found this error:

ERROR: FileAccess::getcsvline: Condition ' eofreached() ' is true. returned: Vector()
At: core\os\file
access.cpp:357
compressing keys: 21
total compressed string size: 175 (175 uncompressed).
bucket table size: 464
hash table size: 92
total collisions: 5
ERROR: FileAccess::getcsvline: Condition ' eofreached() ' is true. returned: Vector()
At: core\os\file
access.cpp:357
compressing keys: 21
total compressed string size: 157 (157 uncompressed).
bucket table size: 464
hash table size: 92
total collisions: 5
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835
ERROR: RasterizerStorageGLES3::texturegetdata: Condition ' !texture->active ' is true. returned: Ref()
At: drivers\gles3\rasterizerstoragegles3.cpp:835

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.