RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login

    Translate games on the fly

    Scheduled Pinned Locked Moved Ideas and Development
    githubideajapanesescripttranslation
    39 Posts 11 Posters 8.8k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • mituM
      mitu Global Moderator @Folly
      last edited by mitu

      @folly said in Translate games on the fly:

      First impression looks like a real nightmare :(

      I think all I needed to add to retroarch.cfg was:

      ai_service_enable = "true"
      ai_service_mode = "0"
      ai_service_pause = "true"
      ai_service_source_lang = "0"
      ai_service_target_lang = "1"
      ai_service_url = "http://ztranslate.net/service?api_key=HEREISMYKEY"
      input_ai_service = "p"
      

      and then pressing P on the keyboard triggered the translation.

      A TPRT 2 Replies Last reply Reply Quote 2
      • A
        AdamBeGood @mitu
        last edited by

        @mitu said in Translate games on the fly:

        @folly said in Translate games on the fly:

        First impression looks like a real nightmare :(

        I think all I needed to add to retroarch.cfg was:

        ai_service_enable = "true"
        ai_service_mode = "0"
        ai_service_pause = "true"
        ai_service_source_lang = "0"
        ai_service_target_lang = "1"
        ai_service_url = "http://ztranslate.net/service?api_key=HEREISMYKEY"
        input_ai_service = "p"
        

        and then pressing P on the keyboard triggered the translation.

        And that is the only step that needs to be followed? I'll definitely try this out then!

        1 Reply Last reply Reply Quote 0
        • F
          Folly
          last edited by Folly

          @mitu @AdamBeGood @Clyde

          Tested it, and it works. :)
          WOW. Thats awesome. Never thought this would be possible.

          Still have somewhat a problem with my hotkey.
          But I will test a bit more.

          edit (issue) :

          It seems the AI "p" key is in conflict with the "pause" function.
          Athough it's commented in the retroarch.cfg like this :

          # input_pause_toggle = p
          

          When I remove the AI_..... lines, translation does not work, but the pause hotbutton does (while commented ?)

          Anyone have an idea how this is possible ?
          This config is edited :
          /opt/retropie/configs/all/retroarch.cfg

          edit (fix) :

          Changed (input_ai_service = "p") into this (input_ai_service = "t")

          No conficts anymore ! :-)

          Now we use the "t" to "translate", isn't that convenient !

          ai_service_enable = "true"
          ai_service_mode = "0"
          ai_service_pause = "true"
          ai_service_source_lang = "0"
          ai_service_target_lang = "1"
          ai_service_url = "http://ztranslate.net/service?api_key=HEREISMYKEY"
          input_ai_service = "t"
          
          1 Reply Last reply Reply Quote 1
          • F
            Folly
            last edited by Folly

            And now .....

            A few pictures ! (Ys (pc88 version))

            before and after :
            2020-11-11-191827_800x600_scrot-1.png 2020-11-11-191827_800x600_scrot-0.png

            Z 1 Reply Last reply Reply Quote 1
            • Z
              Zering @Folly
              last edited by

              @folly That is AWESOME.

              Are there still limits on how much translating we can do?

              F 1 Reply Last reply Reply Quote 0
              • F
                Folly @Zering
                last edited by Folly

                @zering said in Translate games on the fly:

                @folly That is AWESOME.

                Are there still limits on how much translating we can do?

                It still seems to work fine. No limits encountered yet.

                With PC98 I had a few crashes though, when I was in DOS.
                But I use the "tab" key for enabeling the hotkeys.
                That key also responds as keyboard input in some emulators.
                Perhaps it conflicts a bit.
                Don't actually know.

                Overall it seems to work great :)

                Are you going to try this ?

                Z 1 Reply Last reply Reply Quote 0
                • Z
                  Zering @Folly
                  last edited by

                  @folly Eventually, yes, but as I've said on a previous thread I've had a disk failure so I'm focusing on that (I hate myself for having 2 TB of Roms...).
                  At the moment I don't have any untranslated games I can play ^^

                  F 1 Reply Last reply Reply Quote 0
                  • F
                    Folly @Zering
                    last edited by

                    @zering said in Translate games on the fly:

                    @folly Eventually, yes, but as I've said on a previous thread I've had a disk failure so I'm focusing on that (I hate myself for having 2 TB of Roms...).
                    At the moment I don't have any untranslated games I can play ^^

                    Yes, I am aware of that. Good luck with that.
                    If your ready, let me know what you think of it.
                    Would like to hear your opinion.

                    Z 1 Reply Last reply Reply Quote 0
                    • Z
                      Zering @Folly
                      last edited by

                      @folly I'll have to find an untranslated game that I don't have too many expectations for, so I can gauge the quality of the translation and make sure I can actually get the gist of things ;)

                      F 1 Reply Last reply Reply Quote 0
                      • F
                        Folly @Zering
                        last edited by

                        @zering said in Translate games on the fly:

                        @folly I'll have to find an untranslated game that I don't have too many expectations for, so I can gauge the quality of the translation and make sure I can actually get the gist of things ;)

                        Well, It already makes a big difference for menu's.
                        That I know.

                        A 1 Reply Last reply Reply Quote 0
                        • A
                          AdamBeGood @Folly
                          last edited by

                          Mine doesn't seem to work - I've tried putting it into the /all/ retroarch.cfg, and then I tried the pc98 and pc88 ones as well, just in case that works.

                          It is literally just putting the text into that file isn't it? Or are there other steps also?

                          Here is my retroarch.cfg:

                          https://pastebin.com/1VzG5U4w

                          saccublendaS 1 Reply Last reply Reply Quote 0
                          • saccublendaS
                            saccublenda @AdamBeGood
                            last edited by saccublenda

                            @adambegood I think you have to replace HEREISMYKEY with the actual key that you get when you register to the website.

                            A 1 Reply Last reply Reply Quote 1
                            • A
                              AdamBeGood @saccublenda
                              last edited by AdamBeGood

                              @saccublenda said in Translate games on the fly:

                              @adambegood I think you have to replace HEREISMYKEY with the actual key that you get when you register to the website.

                              Great shout! I've amended that now, and still no joy. I am focusing on PC98 so far as that is where I have a few games I'd like to try. I tried putting the code into /pc98/retroarch.cfg also, but that didn't do it.

                              Here's my PC98 config: https://pastebin.com/GNisWHPH

                              I am pressing the keyboard hotkey and the 't' key.

                              Edit: let me have a look at this in the morning, I have had a read around the issue now and hopefully can try some things out.

                              mituM 1 Reply Last reply Reply Quote 0
                              • mituM
                                mitu Global Moderator @AdamBeGood
                                last edited by

                                @adambegood said in Translate games on the fly:

                                Here's my PC98 config: https://pastebin.com/GNisWHPH

                                3rd line from the config says:

                                ai_service_enable = false

                                So the translation service is disabled.

                                A 1 Reply Last reply Reply Quote 1
                                • A
                                  AdamBeGood @mitu
                                  last edited by AdamBeGood

                                  @mitu said in Translate games on the fly:

                                  @adambegood said in Translate games on the fly:

                                  Here's my PC98 config: https://pastebin.com/GNisWHPH

                                  3rd line from the config says:

                                  ai_service_enable = false

                                  So the translation service is disabled.

                                  Derp.

                                  This is why I said I'd look tomorrow, I knew I would have done something stupid.

                                  In my defence, my daughter is sleeping poorly so I am not at 100% over here.

                                  I need to work out if I need to enable this for each system then, surely if the global settings are being overridden by this false line on each individual system setting then I need to edit each system config that I want to use. Don't answer that! I'll work it out.

                                  Thanks very much, @mitu !

                                  Edit: I haven't worked out the global/individual system issue yet, but I have this working on PC98. Clever stuff!

                                  1 Reply Last reply Reply Quote 0
                                  • F
                                    Folly
                                    last edited by Folly

                                    Hi all !

                                    ai_service_mode = "1"
                                    ai_service_pause = "false"
                                    

                                    I was experimenting with translation option again.
                                    When changing the above settings it does not pause and speaks directly the translation to you.

                                    It's also possible to choose many input/output languages.

                                    ai_service_source_lang = "0"
                                    ai_service_target_lang = "1"
                                    

                                    0= not set
                                    1= English
                                    2= Spanish
                                    3= French
                                    4= Italian
                                    5= German
                                    6= Japanese
                                    7= Dutch
                                    etc.... and much more.

                                    Perhaps also interesting for you @dmmarti !

                                    D 1 Reply Last reply Reply Quote 1
                                    • D
                                      dmmarti @Folly
                                      last edited by

                                      @folly Ah nice!!!

                                      I've got a few other computer systems I'm wanting to try .. so this translate tool is awesome.

                                      1 Reply Last reply Reply Quote 1
                                      • DTEAMD
                                        DTEAM
                                        last edited by DTEAM

                                        @folly @mitu
                                        Hi Folly and mitu

                                        If I wanna use a gamepad button to start the translation, what should I do. I've try :

                                        input_ai_service = "nul" # I tried  ---> r3    , r3_btn   14 (#associated with this button)
                                        input_ai_service_axis = "nul"
                                        input_ai_service_btn = "nul" # I tried  ---> r3    , r3_btn   14 (#associated with this button)
                                        input_ai_service_mbtn = "nul"
                                        

                                        nothing works

                                        F mituM 2 Replies Last reply Reply Quote 0
                                        • F
                                          Folly @DTEAM
                                          last edited by

                                          @dteam

                                          I added this in /opt/retropie/configs/all/retroarch.cfg :

                                          input_ai_service_btn = "11"
                                          

                                          Worked perfectly !

                                          You should then use 14 instead, I think.

                                          1 Reply Last reply Reply Quote 1
                                          • mituM
                                            mitu Global Moderator @DTEAM
                                            last edited by

                                            @dteam As @Folly said, you need to add the button's input code, not the name. Look in the .cfg file of your controller (in /opt/retropie/configs/all/retroarch-joypads) and find the input code for the button you want to use, then set the value accordingly for input_ai_service_btn.

                                            DTEAMD 1 Reply Last reply Reply Quote 2
                                            • First post
                                              Last post

                                            Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                                            Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.