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

    Development of module-script generator for lr-mess, lr-mame and mame standalone

    Scheduled Pinned Locked Moved Ideas and Development
    developmentlr-messmamelr-mamescripts
    2.2k Posts 36 Posters 6.1m 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.
    • R
      RussellB @Folly
      last edited by

      @folly I'd love to.

      Here's a question, probably for a new thread. I installed a PixelCade LED marquee in my bartop arcade build which requires a customized EmulationStation that calls web services on the local machine which has a listener to interact with the marquee. I didn't like having to specifically modify ES for this purpose so I implemented three new events: game-select, system-select, screensaver-game-select, and moved the logic to bash scripts. I've seen other threads that discuss wanting this capability. Is that something users would like?

      F 2 Replies Last reply Reply Quote 2
      • F
        Folly @RussellB
        last edited by

        @russellb said in Development of module-script generator for lr-mess and mame standalone:

        @folly I'd love to.

        Great !

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

          @russellb said in Development of module-script generator for lr-mess and mame standalone:

          Here's a question, probably for a new thread. I installed a PixelCade LED marquee in my bartop arcade build which requires a customized EmulationStation that calls web services on the local machine which has a listener to interact with the marquee. I didn't like having to specifically modify ES for this purpose so I implemented three new events: game-select, system-select, screensaver-game-select, and moved the logic to bash scripts. I've seen other threads that discuss wanting this capability. Is that something users would like?

          Looking something like this ?

          Schermafbeelding 2021-05-11 om 08.53.08.png

          I have never used a PixelCade LED marquee, but I would definitly want one, if I had a bartop arcade build.
          Perhaps something for the future.

          Just reading your story, I think you have something good.
          Just use the regular ES and add your bash script are really good arguments to make it simple.
          So this sounds good to me, you should make a thread for that !

          Perhaps we can even add it to our front-end, you never know.

          R 1 Reply Last reply Reply Quote 0
          • R
            RussellB @Folly
            last edited by

            @folly I'll start a new thread. I really like the functionality that was in there so I just leveraged it. I like general solutions that can be reused.

            So:

            game-select receives system name, rom name, game name
            screensaver-game-select receives system name, rom name, game name
            system-select receives system name, type-of-change ("start","input")

            While I'm in there are there any other events that could be useful to intercept?

            RussellB

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

              @russellb

              Well, at the moment I don't have any idea about that, because I know too little about this subject.
              You should explain the process in your thread thoroughly, perhaps then I can get a better idea on what should be in there and what should be added.

              Name me in your thread and I will follow it.

              R 1 Reply Last reply Reply Quote 0
              • R
                RussellB @Folly
                last edited by

                @folly Will do!

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

                  @DTEAM @RussellB

                  I found multiple issues with the front-end module-script.
                  I installed it all from scratch on a x86-64 computer.

                  I made these commits :

                  • https://github.com/FollyMaddy/RetroPie-Share/commit/3669f6ab2b9639cb0ef36bc4d62c8b1c25d175ba
                  • https://github.com/FollyMaddy/RetroPie-Share/commit/c59f653b3e9b80e9f81ca0258866c6bc73bfff3f
                  1 Reply Last reply Reply Quote 1
                  • F
                    Folly
                    last edited by Folly

                    @DTEAM

                    I added the choice to download the images and videos for the gamelists.
                    So after the download the images and videos are displayed in Emulationstation.

                    It worked quite good again.
                    But sometimes, with the downloading, the download script said [Exists].
                    It could be an issue with the gdrivedl.py script.
                    Or perhaps there are double files on your google drive.
                    Can you check that ?

                    Also found something that could improve the gamelists.
                    In the gamelists I found this directory :
                    /home/pi/.emulationstation/downloaded_images/
                    This is a link to :
                    /opt/retropie/configs/all/emulationstation/downloaded_images
                    So we can better use the opt directory, I think.
                    That way other users of RetroPie, that aren't called "pi", can also use the gamelists.

                    This is the commit :
                    https://github.com/FollyMaddy/RetroPie-Share/commit/0671df1a855a67a3b42fcf969c8df8aabf92f5f5

                    DTEAMD 1 Reply Last reply Reply Quote 0
                    • DTEAMD
                      DTEAM @Folly
                      last edited by DTEAM

                      @folly said in Development of module-script generator for lr-mess and mame standalone:

                      Also found something that could improve the gamelists.
                      In the gamelists I found this directory :
                      /home/pi/.emulationstation/downloaded_images/
                      This is a link to :
                      /opt/retropie/configs/all/emulationstation/downloaded_images
                      So we can better use the opt directory, I think.
                      That way other users of RetroPie, that aren't called "pi", can also use the gamelists.

                      Another option could be to put the gamelist.xml and the medias in the rom/system folders.

                      All my new "scrapes" are in my roms folders

                      Or perhaps there are double files on your google drive.
                      Can you check that ?

                      Yes, I'll do

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

                        @dteam

                        I have done some extra research on the gamelists regarding a user independent approach.
                        I did try some things but it seems not working using ~/ for all the entry's.
                        Don't know why.
                        I get back to you, when i found something better.

                        DTEAMD 1 Reply Last reply Reply Quote 0
                        • DTEAMD
                          DTEAM @Folly
                          last edited by DTEAM

                          @folly
                          I'll do It next week, but It will look like this

                          <?xml version="1.0"?>
                          <gameList>
                          	<game id="41424" source="ScreenScraper">
                          		<path>/home/pi/RetroPie/roms/all_in1/bittboy.7z</path>
                          		<name>BittBoy Mini FC 300 in 1</name>
                          		<desc>nes_vt369_vtunknown.cpp
                          </desc>
                          		<image>./media/bittboy.png</image>
                          		<marquee />
                          		<video />
                          		<thumbnail />
                          		<rating>0.8</rating>
                          		<releasedate>20170101T000000</releasedate>
                          		<developer>BittBoy</developer>
                          		<publisher>BittBoy</publisher>
                          		<genre>All in one Handheld console</genre>
                          		<players>1</players>
                          	</game>
                          

                          The gamelist.xml must be in the system room folder like this e.g./home/pi/RetroPie/roms/all_in1/gamelist.xml and all medias (videos, marquees and images) will be in a media folder inside the rom system folder like this : /home/pi/RetroPie/roms/all_in1/media

                          I'll not separate videos, marquees and images in individual folders. It's to much work for nothing.

                          the path is for a .7z file. Did you do something to include .zip. I don't remember.

                          Some themes use <thumbnail> instead of <marquee>. The user will need to make an adjustment if this is the case.

                          Are you agree with that?

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

                            @dteam

                            I have found that changing this :

                            <path>/home/pi/RetroPie/roms/all_in1/bittboy.7z</path>
                            

                            into this :

                            <path>./bittboy.7z</path>
                            

                            Will also work and then it's user independent.
                            We should change that too

                            About the media part :
                            Why do you want it in ./media ?
                            I have some doubts about placing the media into the rom directory's.
                            That way users will always see the directory media in EmulationStation.
                            As an alternative we can also link to some directory's for those who want that.
                            Linking them to ./media if they want or not.

                            Edit : I tested your approach, seems better than I expected.
                            Indeed, the media directory isn't seen in emulationstation.
                            Downloading can be a possible problem with the structure still on google drive.
                            What do you think are the benefits from your perspective ?
                            The ones I can think of are (do you have the same reasons ?):

                            • backup all in on go (roms,media and gamelist)
                            • quick and easy to find in the rom directory for easy access and changing
                            • not mixing with gamelists in /opt/retropie/configs/all/emulationstation/gamelists

                            Btw.
                            It should be quite easy using sed in a cmd line to change them in minutes.

                            DTEAMD 1 Reply Last reply Reply Quote 0
                            • DTEAMD
                              DTEAM @Folly
                              last edited by DTEAM

                              @folly
                              Ok, I'm back

                              The reason why I put those files in the rom directory is for the backup . It's faster to manage but at the end it doesn't matter. I got that from Skraper . They manage "scraping" in the rom folder. What's the easiest way for managing files with your script? I'll do It like you prefer.

                              <?xml version="1.0"?>
                              <gameList>
                              	<game id="41424" source="ScreenScraper">
                              		<path>./bittboy.7z</path>
                              		<name>BittBoy Mini FC 300 in 1</name>
                              		<desc>nes_vt369_vtunknown.cpp
                              </desc>
                              		<image>./media/bittboy.png</image>
                              		<marquee />
                              		<video />
                              		<thumbnail />
                              		<rating>0.8</rating>
                              		<releasedate>20170101T000000</releasedate>
                              		<developer>BittBoy</developer>
                              		<publisher>BittBoy</publisher>
                              		<genre>All in one Handheld console</genre>
                              		<players>1</players>
                              	</game>
                              
                              F 1 Reply Last reply Reply Quote 1
                              • F
                                Folly @DTEAM
                                last edited by Folly

                                @dteam

                                I have been thinking about it.
                                I had some doubts but I think it's a good idea.

                                Do you keep this also in ? :
                                <game id="41424" source="ScreenScraper">
                                There are more of these lines, we could make these just :
                                <game>

                                I think you know, but for easy downloading the ES-media, I think you have to add a media directory in every system directory where the media goes.
                                We should do a test first.
                                But I think it has to like this (as example for all systems) :
                                konamih/media/kgradius.png
                                So it's downloads directly in the correct place when I put the path in.

                                DTEAMD 2 Replies Last reply Reply Quote 1
                                • DTEAMD
                                  DTEAM @Folly
                                  last edited by

                                  @folly said in Development of module-script generator for lr-mess and mame standalone:

                                  Do you keep this also in ? :
                                  <game id="41424" source="ScreenScraper">

                                  It's from an old "scrape" it should be <game > I agree

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

                                    @folly

                                    On Retropie we go with the rom folder, but on Google Drive, can I keep the same structure/folder or I change also that?

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

                                      @dteam said in Development of module-script generator for lr-mess and mame standalone:

                                      @folly

                                      On Retropie we go with the rom folder, but on Google Drive, can I keep the same structure/folder or I change also that?

                                      The structure of the gamelists on google-drive can stay the same.
                                      Only changing the destination path in our script will do the trick.
                                      If I do the same with the media then this will not work.
                                      I will have a second look, if I can do it with the original structure.
                                      I'll be back with the results.

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

                                        @dteam

                                        I had a second look.

                                        For the game-lists, I have no issues with changing the path to the rom directory.
                                        If I do this with the downloaded_images, it puts all .png files inside all the systems directory's.
                                        I don't want to move those files after downloading, so we should change the google-drive folder structure.
                                        Moving the files would also conflict with the lr-mess atwork_overlay .png's that can already be in the same directory.

                                        I think we have to bind both folders on google-drive,
                                        just like we want in our rom directory adding the gamelist.xml and media folder in all system directory's.
                                        Then we can simply use 1 download line in the front-end script.
                                        And if all goes well everything goes to the rom directory in one go.
                                        So we can do a test here.
                                        Can you add the media of konamih into the gamelist folder ?
                                        So you will have a media directory containing the .png's inside this link :
                                        https://drive.google.com/drive/folders/1-HxU0y61KE3d30RUXBki0vwP2tVQh6uo

                                        If you put it there, I will run the script and see if all goes well.
                                        Good idea ?

                                        Edit :
                                        I realized that we can also make the directory structure like this (taking konamih as example) :
                                        -roms
                                        __-konamih (containing the gamelist)
                                        ____-media
                                        _______-emulationstation (containing the theme png's)
                                        _______-overlays_lr-mess (containing the overlay png's)

                                        That way we are far more flexible for the future.
                                        Adding things later on and just have 1 media folder inside the rom directory.
                                        Good idea ?

                                        DTEAMD 1 Reply Last reply Reply Quote 0
                                        • DTEAMD
                                          DTEAM @Folly
                                          last edited by DTEAM

                                          @folly said in Development of module-script generator for lr-mess and mame standalone:

                                          Can you add the media of konamih into the gamelist folder ?

                                          Yes

                                          Good idea ?

                                          Yes, good idea. I'll do that

                                          <?xml version="1.0"?>
                                          <gameList>
                                          	<game>
                                          		<path>./bittboy.7z</path>
                                          		<name>BittBoy Mini FC 300 in 1</name>
                                          		<desc>nes_vt369_vtunknown.cpp</desc>
                                          		<image>./media/emulationstation/bittboy.png</image>
                                          		<marquee />
                                          		<video />
                                          		<thumbnail />
                                          		<rating>0.8</rating>
                                          		<releasedate>20170101T000000</releasedate>
                                          		<developer>BittBoy</developer>
                                          		<publisher>BittBoy</publisher>
                                          		<genre>All in one Handheld console</genre>
                                          		<players>1</players>
                                          	</game>
                                          
                                          DTEAMD 1 Reply Last reply Reply Quote 1
                                          • DTEAMD
                                            DTEAM @DTEAM
                                            last edited by DTEAM

                                            @folly

                                            I did It for konamih and all_in1

                                            You can test It now with those two. I'll try to find time to do the others.

                                            F 1 Reply Last reply Reply Quote 0
                                            • 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.