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

    Versatile C++ game scraper: Skyscraper

    Scheduled Pinned Locked Moved Ideas and Development
    skyscraperscrapergamelist.xmlscrapinggithub
    1.6k Posts 113 Posters 1.6m 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.
    • K
      kb1ujs
      last edited by

      Is there a way to limit what types of resources are scraped? For example, I'm after text resources (descriptions, ratings, etc) but not images.

      muldjordM 1 Reply Last reply Reply Quote 0
      • muldjordM
        muldjord @kb1ujs
        last edited by

        @kb1ujs Videos are off by default (turn on with '--videos'), but images are always scraped and can't be disabled.

        1 Reply Last reply Reply Quote 0
        • AnalogHeroA
          AnalogHero
          last edited by AnalogHero

          @muldjord Just a small bugreport from what ive learned about videoscreensaver: Skyscrapers gamelist.xml files contain empty video tags looking like this <video />

          This is a problem at the moment when using videoscreensavers. Could you make those tags optional somehow?

          muldjordM 1 Reply Last reply Reply Quote 1
          • muldjordM
            muldjord @AnalogHero
            last edited by

            @analoghero Yes, this has been fixed in 2.0.4 which as just been released: https://github.com/muldjord/skyscraper

            1 Reply Last reply Reply Quote 2
            • AnalogHeroA
              AnalogHero
              last edited by

              @muldjord Thanks alot.

              1 Reply Last reply Reply Quote 1
              • muldjordM
                muldjord
                last edited by

                Skyscraper 2.0.5 released: https://github.com/muldjord/skyscraper

                • Added support for 'scummvm' platform in scraping module 'thegamesdb' or 'openretro'.
                • Now only removes 'the' from searchName if longer than 10 chars.
                • Now always converts underscores to spaces in search- and compare names.
                • Added edit distance optimization ('the sequel' will now match 'some game: the sequel' 100%).

                Happy scraping! :)

                1 Reply Last reply Reply Quote 2
                • muldjordM
                  muldjord
                  last edited by

                  A little note on what is going on behind the scenes. I've been looking into creating some sort of GUI for Skyscraper to make it easier to first-time users to get good results. I've had a look at a bunch of sfml and sdl2 based gui frameworks, but not a single one of them are suitable. Believe me, I've been scouring the web for one that fits my requirements, and it's just not gonna happen. They are either too complex, or have too many dependencies to be feasible without making everything unnecessarily complex to install.

                  So, what I've basically decided to do, is to include a 'script-maker' mode when running Skyscraper. It will present the user with a bunch of questions, such as "What platform do you wish to scrape?" and other relevant stuff. And when all questions have been answered, it will create a script or possibly config file (or both) and ask if you want to run it.

                  Comments on this approach will be appreciated.

                  1 Reply Last reply Reply Quote 2
                  • AnalogHeroA
                    AnalogHero
                    last edited by

                    @muldjord Maybe you can go with a shell script gui like the retropie-setup. Dont know if there is any framework there?

                    muldjordM 1 Reply Last reply Reply Quote 1
                    • muldjordM
                      muldjord @AnalogHero
                      last edited by

                      @analoghero Yes, I am also considering that. Although I am partial to the "questionnaire" method since it can then be implemented directly in the software as I see fit. Thanks for suggesting it.

                      B 1 Reply Last reply Reply Quote 0
                      • B
                        bleuge @muldjord
                        last edited by

                        @muldjord I compiled this in Windows using Cygwin some months ago, but got many problems running it. Do you think it is too much effort to make it run ok in Windows, scrapping is lot of faster and easier that connectin to Pi, etc. Thanks!

                        About commandline, I'm happy with it, but I know many users will be too complicated, an interactive shell as you suggest it will ok, while a graphical gui is thought and implemented. If we could run this in Windows i'll do a gui myself if it's needed. Regards!

                        muldjordM 1 Reply Last reply Reply Quote 0
                        • muldjordM
                          muldjord @bleuge
                          last edited by muldjord

                          @bleuge You can easily cross-compile it for Windows. Just download and install Qt 5 from the official site (open source version). When installing, put a checkmark in the latest mingw32 version, I don't support MSVC++ although it might work, not sure. When it's installed you'll find a Qt specific command prompt in your start menu. From there navigate to the Skyscraper source folder and run:
                          $ qmake
                          $ mingw32-make release

                          That will give you a compiled version in a subfolder called "release". Then you need to copy the needed dll's from the qt5 install folder into the release folder and start an ordinary command prompt there. Then you should be able to run it.

                          I thiiiink it will create the .skyscraper data folder inside "C:\Users[username]... somewhere". Just keep in mind that there are some minor Linux specific stuff in Skyscraper's "make install" command that will copy relevant files to the .skyscraper folder. So you'd be missing those. But I believe I auto-create empty ones...

                          So yeah, shouldn't be too hard, but it's not really something I am going to look into myself at this time. Happy hacking! :)

                          1 Reply Last reply Reply Quote 0
                          • B
                            bleuge
                            last edited by

                            Thanks for tips, I already compiled ok in Cygwin (after some work with qt5). Yesterday i updated it and recompiled it. Copied the needed DLLs and ...


                            Running Skyscraper v2.0.5a by Lars Muldjord

                            Please set a valid platform with '-p [platform]'
                            Check '--help' for a list of supported platforms, now exiting...

                            What i meant about windows, was the folder/linux structure, making it portable or something like that. I'll try with some roms to see if i can make it working normally.
                            Thanks!

                            muldjordM 1 Reply Last reply Reply Quote 0
                            • muldjordM
                              muldjord @bleuge
                              last edited by

                              @bleuge I am not sure what you mean. It IS cross-platform compatible (and clearly runs just fine looking at your quoted text). It uses the home folder variable to specify where to save settings, which depends on you OS. So if you are running Windows it will save stuff in the Users folder as expected. Please elaborate.

                              As I mentioned the only thing that isn't cross-platform is the "make install" part which I've made more convenient and automated on Linux. But it shouldn't really be necessary for it to run properly on Windows.

                              B 1 Reply Last reply Reply Quote 0
                              • B
                                bleuge @muldjord
                                last edited by bleuge

                                @muldjord thanks for your answers, i'll elaborate.
                                I have subfolders with roms in c:\roms

                                Skyscraper.exe -p atari2600 -i c:\roms\2600 -t 8 -d c:\roms\00skdb --nobrackets --verbose

                                I got

                                Folder '/home/myuser/.skyscraper/c:\roms\2600/images' doesn't exist, trying to create it... Failed! Please check path and permissions

                                I've looked for .skyscraper file and found that Skyscraper created folders in

                                c:\home\myuser.skyscraper\dbs
                                c:\home\myuser.skyscraper\import...various subs here

                                I don't have any problem Skyscraper creating files and folders whenever it needs it. But well, i can't make it work under Windows.

                                Maybe i can create a config.ini file in the folder of the executable?

                                Thanks for your time, this scraper is very very good! Your idea of the localdb is wonderful.

                                muldjordM 1 Reply Last reply Reply Quote 0
                                • muldjordM
                                  muldjord @bleuge
                                  last edited by

                                  @bleuge I see a potential problem. Please try writing your paths with forward slashes instead of backward slashes.

                                  I do find it odd that it looks for /home/myuser though. I use the builtin user home from Qt, which should adjust for Windows and use the Users folder.

                                  B 1 Reply Last reply Reply Quote 0
                                  • ?
                                    A Former User
                                    last edited by

                                    This might be a tougher request but is it possible to get .7z support for Nintendo DS? DraStic supports .7z and most rom sets are already in that format for the platform.

                                    Thanks.

                                    muldjordM 1 Reply Last reply Reply Quote 0
                                    • B
                                      bleuge @muldjord
                                      last edited by bleuge

                                      @muldjord I updated everything and recompiled it.

                                      This time i ran it at my main pc at home. W10 this time.

                                      I have the skyscrapper executable (and required dlls) in d:\ES\ (emulationstation folder)
                                      Roms in c:\roms\

                                      Skyscraper.exe -p atari2600 -i c:/roms/2600 -t 2 -d c:/roms/00skdb --nobrackets --verbose
                                      Skyscraper.exe -p atari2600 -i c:\roms\2600 -t 2 -d c:\roms\00skdb --nobrackets --verbose
                                      (both work) I changed -t 8 to -t 2, it seems it was hanging for no reason, maybe my connection is too slow. With -t 8 it processed some games and stay there, no more output, with -t 2 it keeps going until end.

                                      Running Skyscraper v2.0.5a by Lars Muldjord
                                      Platform : 'atari2600'
                                      Scraper module : 'thegamesdb'
                                      Input folder : 'c:/roms/2600'
                                      Gamelist folder : 'c:/roms/2600'
                                      Images folder : 'c:/roms/2600/images'
                                      Local db folder : 'c:/roms/00skdb'

                                      Folder '/home/bleuge/.skyscraper/c:/roms/2600/images' doesn't exist, trying to create it... Success!


                                      I've used backslashes or forward, the result is the same. And... where are the files created? In d:\ (where skyscraper exe is and is run) Look the folder structure created by skyscraper:

                                      D:\home\bleuge
                                      D:\home\bleuge.skyscraper
                                      D:\home\bleuge.skyscraper\c?
                                      D:\home\bleuge.skyscraper\dbs
                                      D:\home\bleuge.skyscraper\import
                                      D:\home\bleuge.skyscraper\skipped-thegamesdb.txt
                                      D:\home\bleuge.skyscraper\c?\roms
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb
                                      D:\home\bleuge.skyscraper\c?\roms\2600
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\covers
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\db.xml
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\screenshots
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\videos
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\covers\thegamesdb
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\covers\thegamesdb\47775e7b9ff344126bc7f5ffe33e05c63bea5764.png
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\screenshots\thegamesdb
                                      D:\home\bleuge.skyscraper\c?\roms\00skdb\videos\thegamesdb
                                      D:\home\bleuge.skyscraper\c?\roms\2600\gamelist.xml
                                      D:\home\bleuge.skyscraper\c?\roms\2600\images
                                      D:\home\bleuge.skyscraper\c?\roms\2600\images\Adventure (USA).png
                                      ....

                                      I know this is not designed to work in Windows, but something is going very wrong with folders and file paths, etc... I am very bad at C++, i'll try to find something in the source code.

                                      Look that funny c? ... it's exactly 0x3f char. Also i looked the skipped files list (skipped-thegamesdb.txt ):

                                      --- The following is a list of skipped games ---
                                      'Montezuma's Revenge - Featuring Panama Joe (USA)', Closest match was 'Montezuma's Revenge'
                                      'Basketball (USA)', Closest match was 'BMX Air Master'
                                      'Battlezone (USA)', Closest match was 'Basketball'
                                      'Beamrider (USA)', Closest match was 'Battlezone'

                                      This seems also wrong. Maybe something is going very bad in this windows compile?

                                      Thanks for your time !!!

                                      muldjordM 1 Reply Last reply Reply Quote 0
                                      • muldjordM
                                        muldjord @bleuge
                                        last edited by muldjord

                                        @bleuge I've been thinking about this some more, and I think your problem comes from running it through cygwin. Cygwin is a POSIX env for Windows. If you want to run it on Windows, I suggest you use the Qt provided command line - both for compiling and running it.

                                        Basically cygwin messes with A LOT of the environment stuff. For instance, the home folder for Cygwin is not the Windows home folder. This is a big problem in itself. And 'C:' is '/cygdrive/c' in Cygwin. So when you type in C: on your Skyscraper command line it is not going to work for that reason alone.

                                        So there's a pointer for your further investigation. Simply DON'T use Cygwin and use the official tools provided by Qt instead.

                                        B 1 Reply Last reply Reply Quote 0
                                        • muldjordM
                                          muldjord @A Former User
                                          last edited by

                                          @livefastcyyoung I will add .7z support for all platforms, no problem. :) I will probably do a quick release with just this fix soon. Look out for it on the github page, and here.

                                          1 Reply Last reply Reply Quote 1
                                          • muldjordM
                                            muldjord
                                            last edited by

                                            Skyscraper 2.0.5b released: https://github.com/muldjord/skyscraper

                                            • Added support for '*.7z' files for all platforms

                                            Happy scraping! :)

                                            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.