Home » MODDING HQ 1.13 » v1.13 Modding, Customising, Editing » v1.13 Modding, Customising, Editing » textfile location / translation
textfile location / translation[message #366187] Mon, 08 July 2024 19:03 Go to next message
Felix is currently offline Felix

Messages:4
Registered:July 2024
Location: Germany
Hello. I'm playing the German version and unfortunately not all of the texts have been translated (yet).
I would now like to translate this for myself using Google.

I've already found the texts of the emails. But I can't find the texts of the websites from the laptop.
I also can't find the file with the enemies battle slogans.

Thank you.

Felix

Report message to a moderator

Civilian
Re: textfile location / translation[message #366188 is a reply to message #366187] Tue, 09 July 2024 12:35 Go to previous messageGo to next message
Asdow is currently offline Asdow

 
Messages:146
Registered:August 2010
Most of the text is hardcoded into the actual executable source code, which is the reason we have to compile different ja2.exe files for different languages. There are also a lot of texts externalized to the localized game files.

https://github.com/1dot13/source/blob/master/Utils/_GermanText.cpp
https://github.com/1dot13/source/blob/master/Utils/_Ja25GermanText.cpp
https://github.com/1dot13/gamedir-languages/tree/master/German_Version

Visual Studio Community 2022 is recommended for working on the source code files and compiling an .exe from them. If you do translate something, learning to use git enough to create a pull request to our repository with your changes would be more than welcome.

Report message to a moderator

Sergeant
Re: textfile location / translation[message #366190 is a reply to message #366188] Tue, 09 July 2024 21:56 Go to previous messageGo to next message
Felix is currently offline Felix

Messages:4
Registered:July 2024
Location: Germany
Thanks for the answer.
I'm trying to get to know VS.

Unfortunately, I don't speak English well enough to provide decent translations. I'm also writing this with Google Translate. Personally, I don't care if the game isn't translated correctly.

If I've understood correctly, are all the language files already included in the source? So does that apply to all language versions?
And _GermanText.cpp therefore contains most of the texts? At least I can see one of the texts from the laptop there.
So if I change the _GermanText.cpp file now, I can create a ja2.exe from the source with VS. Right?

And if nobody has a problem with my translations, can I also make the changed files available as a pull request so that someone can integrate them into the source?

PS
Maybe you can help me.
I can open the source in VS and also change files.

But how can I create the JA2.exe from it?
Is there a guide somewhere? All the ones I find show me menus that I don't have in VS.

For example, Build.

[Updated on: Wed, 10 July 2024 01:52]

Report message to a moderator

Civilian
Re: textfile location / translation[message #366191 is a reply to message #366190] Wed, 10 July 2024 04:31 Go to previous messageGo to next message
Kitty

 
Messages:492
Registered:October 2017
Location: Germany
If you go to the 1.13 gitHub, there's a Read-Me at the "source"-repository (at the bottom, scroll down a little):

gitHub-1dot13-source

The readme has a description on how to do the VS setup and use of CMake to build the possible .exe(s)




How to get: latest 1.13, 7609 and more | 7609 SCI (eng) | Compiling+SVN

I need more details. (Didi Hallervorden)

Report message to a moderator

Master Sergeant
Re: textfile location / translation[message #366192 is a reply to message #366187] Wed, 10 July 2024 08:07 Go to previous messageGo to next message
Felix is currently offline Felix

Messages:4
Registered:July 2024
Location: Germany
Thanks. I've already tried it.
But now I know where my mistake was. I was missing some components in VS. Like .net and c++. After I installed them, I was able to follow the instructions from the read.me without any problems.

But when I create the exe I get a bunch of warnings. Mainly the C4838. But also a few from C4805, C4715, C4477 and C4244.

I can still start the game and see my changes.

Unfortunately I have absolutely no idea about C++ or anything else, which makes working with VS quite difficult. happy

Would it help to use VS 2019 instead of VS 2022?

Report message to a moderator

Civilian
Re: textfile location / translation[message #366193 is a reply to message #366192] Wed, 10 July 2024 10:29 Go to previous messageGo to next message
Asdow is currently offline Asdow

 
Messages:146
Registered:August 2010
Compiler warnings are normal when building the .exe from JA2 source code. It's 25 years of C/C++ spaghetti code that wasn't necessarily done with the most strict coding quality. ;) If it compiles and works, you're doing it correct.

Report message to a moderator

Sergeant
Re: textfile location / translation[message #366194 is a reply to message #366193] Wed, 10 July 2024 15:58 Go to previous messageGo to next message
Felix is currently offline Felix

Messages:4
Registered:July 2024
Location: Germany
I almost thought so. I was still hoping there might be a solution. :/

Two more questions.
When I create the exe, do I have to put all the files in again or can I somehow just replace the one changed file?
It takes me ages to create it and that's just when I want to test one line.

And about the translation. At the beginning of the .cpp it says: "Always be aware that German strings should be of equal or shorter length than the English equivalent."

How do you translate a word when the only German word is twice as long?
Or how can I tell in the file whether a longer one will fit? I guess you just have to test it?

But I've noticed that some things are missing in the German text file. This causes a few bugs. You'd have to compare line by line with the English file to see what's missing.
And translating is also a lot of hard work with the amount of text.

Report message to a moderator

Civilian
Re: textfile location / translation[message #366195 is a reply to message #366194] Wed, 10 July 2024 18:51 Go to previous message
Kitty

 
Messages:492
Registered:October 2017
Location: Germany
If you use the exe with the same gamedir, just replacing the exe should do.

It shouldn't take to long to build if you only change one line

About the string length, that's refering to its total length, not specific words

A direct translation often will fail that, a little creativity and bending of some rules might do it

Like:

"NPC is hungry." = 14 (including all empty space and signs)

"NPC ist hungrig." = 16 (too long compared to 14)

"NPC hat Hunger." = 15 (better, but still too long)

"NPC hat Hunger" = 14  (yay, that'll do) (screw the dot (.) and it has the same length)

[Updated on: Wed, 10 July 2024 18:52]




How to get: latest 1.13, 7609 and more | 7609 SCI (eng) | Compiling+SVN

I need more details. (Didi Hallervorden)

Report message to a moderator

Master Sergeant
Previous Topic: Non lockable doors when adding more doors types to a tileset.
Next Topic: Pass-trough sandbags..
Goto Forum:
  


Current Time: Fri Feb 14 11:13:47 GMT+2 2025

Total time taken to generate the page: 0.01292 seconds