Change Built in Scraper Image path?
-
I've been trying to come up with a scraper solution that I am happy with. The built in scraper is really slow so I do not like using it. I attempted to use the GUI SSelph scraper that's built in, but ran into some issues saying roms had been scraped when they haven't. (even tried append method)
The best approach I have found is to just install the SSelph scraper manually. Then I run "scraper -thumb_only". This is pretty quick and works well. It stores the gamelist.xml and images in the rom directory which I like. However due to the nature of roms the hash isn't always found. For instance it can't find Goldeneye for the N64. Obviously it exists on thegamedb.net. I tried the other command line options and I couldn't find a match.
So this is where I'm at. I know there is the -missing files.csv command line argument I could use, and I could submit it somewhere. But I'm sure Goldeneye is already there. I probably just have a weird rom copy. It works and plays as good as it can on my Pi 2. The point is that I think I'm stuck at this point. I wish there was a way to take this .csv output, manually add thegamedb ids or URLS in an adjacent column, and feed it back in.
So the best approach I have found in this scenario is to run the built in scraper. I set it to only scrape the N64 system for games "missing images only". So this will scrape anything that SSelphs scraper couldn't match a hash on and it will allow me to manually resolve conflicts. It finds Goldeneye, I select it, and everything looks well. The metadata is there and the game box appears.
The thing I don't like about this is the file location. It does utilize the same gamelist.xml in the roms directory (the same file SSelph's scraper created and updates), but the images don't utilize the image folder in the rom directory. They end up going to /home/pi/.emulationstation/downloaded_images/n64/ I can't seem to find any anywhere that this can be configured. Does anyone know if this is possible?
I suppose worst case scenario I can just live with gameart existing in two different directories. But if its somehow possible to configure the built in scraper to use the roms/<system>/images folder I'd like to do it.
-
@fastfalcon94 the path cannot be changed in ES. Like a lot of things this is hardcoded into EmulationStation. The project is essentially dead, apart from a few tweaks from Recalbox and Retropie. If you want to change it the source code is available to download. You could decompile, alter, rebuild, test and install it yourself. A total PITA but that's the way it is. Some things can be customised and configured. Others can't. Well, not easily.
-
A script could be written to achieve what you want. It could automatically create and copy files to your desired path as they are scraped.
-
Thanks for your help. I attempted to write a shell script but I had a ton of problems. I resorted to Perl (A language I used a lot in college 10 years ago) but still ran into issues. I could get it to copy the image files, but ran into regular expression trouble trying to update the XML. Basically I couldn't get this command to ever work:( I guess I'll just live with the rom images potentially being in 2 different locations for now. It sucks the project is dead. I see they did some other stuff I didn't like with the Carbon theme. They stripped it down taking out labels and ratings. It took me forever to figure out how to edit the theme and get what I wanted lined up again.
perl -pi.bak -e's//home/pi/.emulationstation/downloaded_images/n64/007 - GoldenEye-image.jpg//home/pi/RetroPie/roms/n64/images/007 - GoldenEye-image.jpg/g' /home/pi/RetroPie/roms/n64/gamelist.xml
-
Actually I figured out how to make it work. Script is here in case anyone else wants to use it: www.802projects.com/documents/movescrapes.zip
To run just do "perl movescrapes.pl" after extracting it anywhere. There is an array at the top you can add to or adjust to list the systems you want to move files. It will copy any game image from the built in scraper directory to the roms/images folder for a given system. Then it will edit the gamelist.xml file in the rom directory and update any path that pointed to the image file in the build in scraper directory to the /images folder in the rom directory. It makes a backup of the gamelist.xml first in each system directory called gamelistbackup.xml
-
If I understand correctly, wouldn't it be easier to simply create a symlink to the desired image folder? That way images end up being stored in the same place and no need to modify the xml.
-
@synack As far as the end user is concerned it works just fine as is. They scrape from SSelph and it gets say 90% for a given system. Then they scrape from the built in scraper (by filtering on roms with no images, the games db, and for the given system). They manually resolve conflicts. Now they may have about 99% of the roms scraped for that system. 90% of the images are in the directory SSelph scraper uses, 9% are in the directory the built in scraper uses, and 1% couldn't be found. So it all works. Me (and my OCD ha) would like it if all the image files were in SSelph's directory. So your options are
- leave it as -is and don't worry about it
- Manually copy the images over to SSelphs directory, then open up the gamelist in notepad and find and replace
- Write a script (or use the script I wrote) to do #2 automatically
In honesty I should have just done #2. I sent more time testing and getting the script to work. If I just manually did it I'd have it done in probably 20 minutes.
I've tested it so far on the virtual boy, the n64, the Sega 32x and the SG1000 system and the script seems to work fine each time. I wish I could get to 100%. The "Add Input" button in emulation station is weird. I can find WWF RAW on thegamesdb.net but I can't seem to type in anything in emulation station to find it. I wish I could just type in the gameid in the "Add Input" button in Emulation Station.
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.