RETROBAT Official Board
Would you like to react to this message? Create an account in a few clicks or log in to continue.

how to make a choice of different versions of the emulator?

3 posters

Go down

how to make a choice of different versions of the emulator? Empty how to make a choice of different versions of the emulator?

Post by Triceratops 05/10/24, 12:16 pm

I have two different versions of ryujinx emulators, I tried to add the second emulator, but when I try to launch it, an error occurs that the emulator is not found.

It seems that adding new emulators is impossible, but I just want to launch another version. Is it possible to somehow make it so that you can choose which version of the emulator to launch in the menu?

how to make a choice of different versions of the emulator? Latest10
Triceratops
Triceratops

Messages : 9
Date d'inscription : 2024-09-15

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by getupor 05/10/24, 12:17 pm

Hello

And the question : why having 2 versions of Ryujinx ?


how to make a choice of different versions of the emulator? Admin4
getupor
getupor
Admin

Messages : 1422
Date d'inscription : 2020-10-04

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by Triceratops 05/10/24, 12:21 pm

getupor wrote:Hello

And the question : why having 2 versions of Ryujinx ?

because I added an additional line for the new emulator to the config, I also made a new folder, and wrote all the paths in the additional files. but nothing worked, and the program crashes on an error
Code:

2024-10-05 19:45:23.749 [INFO]      [Startup] "K:\RetroBat\emulationstation\emulatorLauncher.exe"  -gameinfo "C:\Users\Retro\AppData\Local\Temp\emulationstation.tmp\game.xml"  -system switch -emulator ryujinx-latest -core "K:\RetroBat\emulators\ryujinx-latest\Ryujinx.exe"  -rom "K:\RetroBat\roms\switch\Luigis Mansion 3 [0100DCA0064A6000][v0] (6.35 GB).nsp"
2024-10-05 19:45:23.750 [INFO]      [Startup] Loading configuration.
2024-10-05 19:45:23.754 [INFO]      [Startup] Loading ES settings.
2024-10-05 19:45:23.798 [INFO]      [Game] Luigi's Mansion 3
2024-10-05 19:45:23.801 [INFO]      [Startup] Loading Controller configuration.
2024-10-05 19:45:23.996 [ERROR]     [Generator] Can't find generator
2024-10-05 19:45:23.996 [ERROR]     [Generator] Exit code 203

there are many version of ryujinx but the latest one is unstable in some games so i would like to have two versions of this emulator one latest for some games one previously created with lower version for others
Triceratops
Triceratops

Messages : 9
Date d'inscription : 2024-09-15

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by tartifless 05/10/24, 12:43 pm

Hello,

This is not possible as RetroBat links an emulator to a generator in its core program.
So ryujinx-latest ==> does not exist in our code.


how to make a choice of different versions of the emulator? Admin4
tartifless
tartifless
Admin

Messages : 1674
Date d'inscription : 2021-04-27

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by Triceratops 05/10/24, 01:10 pm

tartifless wrote:Hello,

This is not possible as RetroBat links an emulator to a generator in its core program.
So ryujinx-latest ==> does not exist in our code.

I would be very grateful if you added the ability to create emulators of different versions by referring to the main emulator generator (for example, by specifying an optional parameter for generation).

Code:
<command>"%HOME%\emulatorLauncher.exe" -gameinfo %GAMEINFOXML% %CONTROLLERSCONFIG% -system %SYSTEM% -emulator %EMULATOR% -core %CORE% -rom %ROM%</command>
   <emulators>
     <emulator name="ryujinx"/>
     <emulator parent="ryujinx" name="ryujinx-latest"/>
     <emulator name="sudachi"/>
     <emulator name="suyu"/>
     <emulator name="yuzu"/>
     <emulator name="yuzu-early-access"/>
   </emulators>

or some special parameters for the core



Code:
<command>"%HOME%\emulatorLauncher.exe" -gameinfo %GAMEINFOXML% %CONTROLLERSCONFIG% -system %SYSTEM% -emulator %EMULATOR% -core %CORE% -rom %ROM%</command>
   <emulators>
     <emulator name="ryujinx"/>
            <cores>
                <core>ryujinx</core>
                <core>ryujinx-latest</core>
           </cores>
     <emulator name="sudachi"/>
     <emulator name="suyu"/>
     <emulator name="yuzu"/>
     <emulator name="yuzu-early-access"/>
   </emulators>
Triceratops
Triceratops

Messages : 9
Date d'inscription : 2024-09-15

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by Triceratops 06/10/24, 08:32 am

In general, I dug into the code and realized that I only need to correct two lines of code to use the desired generator

Program.cs
Code:

            string emulatorName = SystemConfig["emulator"].Split('_')[0];
            Generator generator = generators.Where(g => g.Key == emulatorName).Select(g => g.Value()).FirstOrDefault();

I just made a small check to filter up to the "_" symbol, thereby simply ignoring the remaining symbols

I also corrected the code in the Ryujinx.Generator.cs so that it generates a new path (similar to Yuzu)
Ryujinx.Generator.cs
Code:
           string path = AppConfig.GetFullPath(emulator.Replace("_", " "));
            if (string.IsNullOrEmpty(path) && emulator.Contains("-"))
                path = AppConfig.GetFullPath(emulator);

            // string path = AppConfig.GetFullPath("ryujinx");
            // if (!Directory.Exists(path))
            //    return null;

I posted the compiled file on GitHub
Triceratops
Triceratops

Messages : 9
Date d'inscription : 2024-09-15

Back to top Go down

how to make a choice of different versions of the emulator? Empty Re: how to make a choice of different versions of the emulator?

Post by Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum