Coder Social home page Coder Social logo

Comments (28)

foubou avatar foubou commented on June 30, 2024 1

Don't worry, I will try to help you the best I can to solve your problem ! ;)

from translationframework2.

Kaplas80 avatar Kaplas80 commented on June 30, 2024

Hello!

To change the font in this game, you have to:

  1. Create the font images (FONTXXX.DA_) and replace the original ones using TF2
  2. If you want to use other characters than the ones included in the Spanish font, you'll have to modify the plugin source code and add the characters you need.
  3. Adjust each character width in the exe using TF2

The main problem is that we can use all the characters we need because the game only allows a limited number of variable width characters.

I think @foubou made a French translation of this game, so he had to deal with those characters. Maybe he can send you the font files and the needed code modifications.

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Hi ! Yes, I think I can help with the missing characters, but I need time to prepare the tool and the files.
I'll reply here when it's ready !
@LluisCat In what language do you want to translate the game ?

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Hi ! Yes, I think I can help with the missing characters, but I need time to prepare the tool and the files.
I'll reply here when it's ready !
@LluisCat In what language do you want to translate the game ?

Hello! I want to translate the game into Catalan.
These are the extra characters used: àèò ïü éíóú ç ÀÈÒ ÏÜ ÉÍÓÚ Ç · «»
Also, when writing "l·l" a halfwidth "L l" would be advisable

As I said, I made the font myself and inside TF2 the font is correct, but inside the game the characters are not showing. Maybe I'm not doing something correct when creating the font, or I'm missing some step. I tried to change plugin source code as @Kaplas80 said, but the result is the same. I don't really understand what is the problem.

Example:
Captura de pantalla 2021-05-26 142814

exemple malament

Thank you for answering and for your help ^^

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Here is a tool you can try : https://drive.google.com/file/d/1p2fAjMbRX0x8Wk456d6XM--WUwKS8ljK/view?usp=sharing
Just follow the instructions to make it work.
If you have troubles using it, I am here to help you. ;)
Good luck !

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Here is a tool you can try : https://drive.google.com/file/d/1p2fAjMbRX0x8Wk456d6XM--WUwKS8ljK/view?usp=sharing
Just follow the instructions to make it work.
If you have troubles using it, I am here to help you. ;)
Good luck !

Hello, I can't enter this link. An error appears saying it fails to comply with terms and conditions :/

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Oh sorry, let me fix it !

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Try this new link : https://drive.google.com/drive/folders/1MKzpKV9DFNx6SreJjLn0576zJfdI2rnD?usp=sharing

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Try this new link : https://drive.google.com/drive/folders/1MKzpKV9DFNx6SreJjLn0576zJfdI2rnD?usp=sharing

Okay, this time it is working. Thank you ^^ I will ask you if I have any problem.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Try this new link : https://drive.google.com/drive/folders/1MKzpKV9DFNx6SreJjLn0576zJfdI2rnD?usp=sharing

I am trying and trying and I don't know what's wrong ;-;
I created the font using your folder and first I didn't have Ed6Back.exe because I didn't know I needed it but it created the fonts anyway. After that, I imported the files in TF2 but I get the same results as always. The font is showing right in the program, not in the game.
After that I tried downloading Ed6Back.exe but when I paste the fonts created with this .exe they show buggy in TF2. Anyway, the result in game is the same.
Are you using TF2 to translate? Because I think maybe the problem is with the program encoding that can't recognize these characters when creating the text files... (The "plugin source code" @Kaplas80 mentioned) Also, when I'm creating the font this error appears: "ERROR?0Character: À" (for every letter) I don't know if this is normal.

font creada amb la seva ajuda
(Font without Ed6Back.exe)
bugged font
(Font with Ed6Back.exe)
línia modificada
(Text that I wrote in TF2)
prova ultra fallida
(Text in game with ED6_DT00 that appears in "to_copy_inside_game_folder")
prova 2
(Text in game with ED6_DT00 modified with TF2)

from translationframework2.

Kaplas80 avatar Kaplas80 commented on June 30, 2024

The problem is that you are using characters over 0xDF (à = 0xE0). If the string has any character over 0xDF, the game reads it as the first byte of a two-byte character and that's why it shows strange symbols.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

The problem is that you are using characters over 0xDF (à = 0xE0). If the string has any character over 0xDF, the game reads it as the first byte of a two-byte character and that's why it shows strange symbols.

So what is the solution to this? How I can use these characters without showing other symbols?
What do I have to modify? I'm not experienced enough to solve this by myself.

from translationframework2.

foubou avatar foubou commented on June 30, 2024

You are right, it might be an encoding problem.
I am using a custom TF2 to translate the menus only. For the scenario, I am using spreadsheets and another tool made by a friend. I don't know what my friend modified though, I have little knowledge about programming.
To compile scripts, I am also using the font tool made by ZhenjianYang.
https://github.com/ZhenjianYang/SoraTranslation-Tools
https://github.com/ZhenjianYang/SoraTranslation-Tools/tree/master/examples/french
This tool has a special encoding and you can try to modify some of the values to display properly your characters. (see screenshot).
I'll run some tests myself and I'll let you know if I find a solution. ;)
zhen tool values

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

You are right, it might be an encoding problem.
I am using a custom TF2 to translate the menus only. For the scenario, I am using spreadsheets and another tool made by a friend. I don't know what my friend modified though, I have little knowledge about programming.
To compile scripts, I am also using the font tool made by ZhenjianYang.
https://github.com/ZhenjianYang/SoraTranslation-Tools
https://github.com/ZhenjianYang/SoraTranslation-Tools/tree/master/examples/french
This tool has a special encoding and you can try to modify some of the values to display properly your characters. (see screenshot).
I'll run some tests myself and I'll let you know if I find a solution. ;)

Before trying TF2 I was trying Sora Translation tools and I made my first custom font there, but when using"3.compile_scripts" this error appeared (I opened an issue there, but nobody answered):

C:\Users\Lluis\SoraTranslation-Tools\examples\french>(
title Compiling C0100
 py "py\C0100.py" "--cppy=..\..\SoraTrs\SoraSJIS.py" "--chlist=chlist.txt" "--gp=dir" "scena"
)
Traceback (most recent call last):
  File "C:\Users\Lluis\SoraTranslation-Tools\examples\french\PyLibs\ouroboros\dbghelp\invoker.py", line 6, in Try
    return method(*values)
  File "C:\Users\Lluis\SoraTranslation-Tools\examples\french\py\C0100.py", line 6, in main
    CreateScenaFile(
  File "C:\Users\Lluis\SoraTranslation-Tools\examples\french\EDDecompiler\Decompiler\ED6FCScenaFile.py", line 81, in CreateScenaFile
    initDatFileNameTable(GAME_PATH)
  File "C:\Users\Lluis\SoraTranslation-Tools\examples\french\EDDecompiler\Decompiler\Base\ED6FCBase.py", line 46, in initDatFileNameTable
    n = buf[i:i+0x10].split(b'\x00', 1)[0].decode(CODE_PAGE)
LookupError: unknown encoding: Sora-SJIS

So now I'm in this situation in which everything is failing.

from translationframework2.

Kaplas80 avatar Kaplas80 commented on June 30, 2024

TF2 replaces the characters over 0x7F and that's why I told @LluisCat to edit the plugin source to add the characters he needs.

new Tuple<string, string>("É", "\u0026"), //&
new Tuple<string, string>("Í", "\u0027"), //'
new Tuple<string, string>("á", "\u003B"), //;
new Tuple<string, string>("é", "\u005C"), //\
new Tuple<string, string>("í", "\u005E"), //^
new Tuple<string, string>("ó", "\u005F"), //_
new Tuple<string, string>("ú", "\u0060"), //`
new Tuple<string, string>("ü", "\u007B"), //{
new Tuple<string, string>("ñ", "\u007D"), //}
new Tuple<string, string>("¡", "\u007E"), //~
new Tuple<string, string>("¿", "\u007F"), //DEL

You can add other replacements like new Tuple<string, string>("à", "\u00DF"), but you won't be able to adjust their width.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

TF2 replaces the characters over 0x7F and that's why I told @LluisCat to edit the plugin source to add the characters he needs.

new Tuple<string, string>("É", "\u0026"), //&
new Tuple<string, string>("Í", "\u0027"), //'
new Tuple<string, string>("á", "\u003B"), //;
new Tuple<string, string>("é", "\u005C"), //\
new Tuple<string, string>("í", "\u005E"), //^
new Tuple<string, string>("ó", "\u005F"), //_
new Tuple<string, string>("ú", "\u0060"), //`
new Tuple<string, string>("ü", "\u007B"), //{
new Tuple<string, string>("ñ", "\u007D"), //}
new Tuple<string, string>("¡", "\u007E"), //~
new Tuple<string, string>("¿", "\u007F"), //DEL

You can add other replacements like new Tuple<string, string>("à", "\u00DF"), but you won't be able to adjust their width.

Well, I changed
new Tuple<string, string>("á", "\u003B"), //; to new Tuple<string, string>("à", "\u003B"), //;
but I don't see any difference.

For example, I wrote the sentence: El pare fa tárd tàrd
spanish font with à
This is the game using the Spanish font but using new Tuple<string, string>("à", "\u003B"), //;

catalan font
This is the game using my custom font and using new Tuple<string, string>("à", "\u003B"), //;

Why is "á" still working if I removed it from Encoding.cs?
Captura de pantalla 2021-05-27 172023
Captura de pantalla 2021-05-27 171022

from translationframework2.

Kaplas80 avatar Kaplas80 commented on June 30, 2024

I think you have changed the code but have not recompiled the dll or replaced it in the plugins folder.

from translationframework2.

foubou avatar foubou commented on June 30, 2024

TF2 SOURCE
You have to build the tool from source.
Download VisualStudio and the TF2 source files, make your changes and launch TranslationFramework2.sln

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Oh, okay. Now I understand the problem. I downloaded both the compiled version and the VisualStudio version. So I wasn't changing anything when modifying the script. I'm sorry you have to bear with me and my little programming knowledge. I guess I'll try downloading VisualStudio and see if I get to solve anything.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Well, after hours and hours of fighting, I ALMOST got the expected result. In the first red box a "À" should appear, in the second one a "Ü" and in the third one a "Ç". I don't know why they aren't showing. ;-;

fail

codi

font

text

Also @foubou the tool you provided creates fonts without "ò" "ú" and other characters I need. Do you know if it is possible to modify it to include them?

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Well, after hours and hours of fighting, I ALMOST got the expected result. In the first red box a "À" should appear, in the second one a "Ü" and in the third one a "Ç". I don't know why they aren't showing. ;-;

Good job for making it work ! The "À" "Ç" "Ü" should appear in-game if they are in your chlist file and in TF2.
missing chars

Can you send me a translated ._SN file please ? I'd like to run some tests and see how catalan characters are displayed with my tools and setup.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

The files are directly in .dat and .dir because I'm translating with TF2. I have the ._SN file, but I don't think it is going to work because it has the wrong encoding and I don't know how to apply it with "3.compile_scripts". It gives me an error.

There's only one translated sentence, the second sentence from the beginning of the game. Here are the files: https://drive.google.com/drive/folders/1vtP-HJpJObqXlUNaLfzYutaAivGA50dM?usp=sharing

Also, my chlist has all the characters. I don't know where is it failing.
Captura de pantalla 2021-05-28 122625

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Thank you for uploading your files. I'll make some tests when I have time. ;)

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Thanks to you! :) Meanwhile, I will be making some more tests to see if changing the position of these letters or something fixes the problem.

from translationframework2.

stale avatar stale commented on June 30, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Hello, @foubou I've been busy this time, but in the future I would like to continue and get help for the fonts because I can't get to separate well the letters from each other. Would you give me your e-mail for contact, please? It would be appreciated.
After this I think I can close the thread because the main problem was solved.

from translationframework2.

foubou avatar foubou commented on June 30, 2024

Oh !! Really sorry Luis, I was busy too with other projects and completely forgot to come back to you.
My mail is [email protected]
Feel free to contact me anytime ! I will have some time this week-end.

from translationframework2.

LluisCat avatar LluisCat commented on June 30, 2024

Oh !! Really sorry Luis, I was busy too with other projects and completely forgot to come back to you.
My mail is [email protected]
Feel free to contact me anytime ! I will have some time this week-end.

I understand, I'm in other projects too haha. I will do so ^^

from translationframework2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.