Kodi Community Forum
[RELEASE] Rom Collection Browser - Browse and launch emulator game ROMs - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Game Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=291)
+---- Thread: [RELEASE] Rom Collection Browser - Browse and launch emulator game ROMs (/showthread.php?tid=70115)



- Tomkun - 2010-09-05

@malte

Is it possible to make the tag %GAME% available to <emulatorCmd>?
I ask because PCSX2 has the ability to have separate settings files per game, but they need to be passed along in the command line.


- malte - 2010-09-05

carabalb Wrote:Hey Malte, is there any way to easily implement a launch before and a launch after command in the existing code?

If you start the emu in solo mode the easiest way would be to write an additional command in applaunch.bat or applaunch.sh.

In python code you will find the launch command in helper.py (line 451 I think). Search for "os.system(cmd)". You could write another "os.system(your command here)" before and after. If this is really a common scenario for specific emus I could add this as a configurable option in a later release.


hikaricore Wrote:For example if I load umk3.zip the emu will also load umk3r10.zip & umk3r11.zip.
But this isn't done from launch, launch is simply: sdlmame %ROM%
So it actually should just run: sdlmame umk3.zip
Like I said it's odd because it never gets to this point.

I have to check this in the code again. RCB should only try to handle this as multi rom if you have configured a "diskPrefix" in config.xml. But in this case I guess I have to add an option to ignore the additional rom files. Something like this is not implemented right now.


hikaricore Wrote:I've also run into another small problem with file naming.
The database doesn't differentiate between two files with the same name but different extensions and import dies when this occurs:

Are you using version 0.5.x (the latest in repo)? This should be fixed with 0.6.x. Currently not available via repo because I want to fix one little issue before I submit it (On some systems it does always think that config.xml has been changed and offers you to import settings at every startup).


TioSolid Wrote:Does RCB support .dat files in any way? I think supporting these kind of files (from clrmamepro for example) would pretty much solve all the description problems for almost every console.

They are xml files, or? Not in the current version but this is the feature that I am working on atm. If this is done there will be a configurable way to import different xml formats. I think this .dat should work also.

But I am not sure if I can add these features step by step with some minor releases in between or if I have to throw a bomb in my code and have to wait a longer time before I can release a new version with xml (and scraping) support.


Tomkun Wrote:Is it possible to make the tag %GAME% available to <emulatorCmd>?
I ask because PCSX2 has the ability to have separate settings files per game, but they need to be passed along in the command line.

Will be no big thing. But %GAME% is really the game name that is displayed as title in RCB. So this may be "Legend of Zelda: Link to the past" or something like this (containing characters that are not allowed in file names). I have an item like this on my list for a long time (handling per game configurations) but until now no good idea how to do this. Adding %GAME% placeholder could be a start but I think it will run into problems in some situations.


- hikaricore - 2010-09-05

malte Wrote:Are you using version 0.5.x (the latest in repo)? This should be fixed with 0.6.x. Currently not available via repo because I want to fix one little issue before I submit it (On some systems it does always think that config.xml has been changed and offers you to import settings at every startup).

Woops didn't even see that I was a version behind. >.>
I'll test it out tomorrow and see if that solves my problem. Smile

*edit* Seems 0.6 fixes both of my problems, lol I'll pay more attention from now on. Thanks again ^_^


- XBMCG33K - 2010-09-05

This error only happens when I try to configure the script:

Quote:04:18:43 T:2940 M:1195827200 DEBUG: SDLKeyboard: scancode: 1, sym: 27, unicode: 27, modifier: 0
04:18:43 T:2940 M:1195827200 DEBUG: CApplication::OnKey: 61467 pressed, action is PreviousMenu
04:18:43 T:2940 M:1195761664 DEBUG: CGUIWindowManager:TonguereviousWindow: Deactivate
04:18:43 T:2940 M:1195761664 DEBUG: ------ Window Deinit (SettingsCategory.xml) ------
04:18:44 T:2940 M:1195315200 DEBUG: CGUIWindowManager:TonguereviousWindow: Activate new
04:18:44 T:2940 M:1195315200 DEBUG: ------ Window Init (Settings.xml) ------
04:18:44 T:2940 M:1195315200 INFO: Loading skin file: Settings.xml
04:18:46 T:2940 M:1190260736 DEBUG: SDLKeyboard: scancode: 1, sym: 27, unicode: 27, modifier: 0
04:18:46 T:2940 M:1190260736 DEBUG: CApplication::OnKey: 61467 pressed, action is PreviousMenu
04:18:46 T:2940 M:1190260736 DEBUG: CGUIWindowManager:TonguereviousWindow: Deactivate
04:18:46 T:2940 M:1190260736 DEBUG: ------ Window Deinit (Settings.xml) ------
04:18:47 T:2940 M:1190764544 DEBUG: CGUIWindowManager:TonguereviousWindow: Activate new
04:18:47 T:2940 M:1190764544 DEBUG: ------ Window Init (Home.xml) ------
04:18:47 T:2940 M:1190764544 INFO: Loading skin file: Home.xml
04:18:50 T:2940 M:1187209216 DEBUG: SDLKeyboard: scancode: 77, sym: 275, unicode: 0, modifier: 0
04:18:50 T:2940 M:1187209216 DEBUG: CApplication::OnKey: 61479 pressed, action is Right
04:18:50 T:2940 M:1186836480 DEBUG: SDLKeyboard: scancode: 77, sym: 275, unicode: 0, modifier: 0
04:18:50 T:2940 M:1186836480 DEBUG: CApplication::OnKey: 61479 pressed, action is Right
04:18:51 T:2940 M:1187049472 DEBUG: SDLKeyboard: scancode: 77, sym: 275, unicode: 0, modifier: 0
04:18:51 T:2940 M:1187049472 DEBUG: CApplication::OnKey: 61479 pressed, action is Right
04:18:51 T:2940 M:1186398208 DEBUG: SDLKeyboard: scancode: 77, sym: 275, unicode: 0, modifier: 0
04:18:51 T:2940 M:1186398208 DEBUG: CApplication::OnKey: 61479 pressed, action is Right
04:18:52 T:2940 M:1187749888 DEBUG: SDLKeyboard: scancode: 77, sym: 275, unicode: 0, modifier: 0
04:18:52 T:2940 M:1187749888 DEBUG: CApplication::OnKey: 61479 pressed, action is Right
04:18:52 T:2940 M:1187856384 DEBUG: SDLKeyboard: scancode: 28, sym: 13, unicode: 13, modifier: 0
04:18:52 T:2940 M:1187856384 DEBUG: CApplication::OnKey: 61453 pressed, action is Select
04:18:52 T:2940 M:1187856384 DEBUG: CApplication::ExecuteXBMCAction : Translating ActivateWindow(1)
04:18:52 T:2940 M:1187856384 DEBUG: CApplication::ExecuteXBMCAction : To ActivateWindow(1)
04:18:52 T:2940 M:1187856384 DEBUG: Activating window ID: 10001
04:18:52 T:2940 M:1187856384 DEBUG: Checking if window ID 10001 is locked.
04:18:52 T:2940 M:1187856384 DEBUG: ------ Window Deinit (Home.xml) ------
04:18:53 T:2940 M:1188081664 DEBUG: ------ Window Init (MyPrograms.xml) ------
04:18:53 T:2940 M:1188081664 INFO: Loading skin file: MyPrograms.xml
04:18:53 T:2940 M:1186742272 DEBUG: CGUIMediaWindow::GetDirectory ()
04:18:53 T:2940 M:1186742272 DEBUG: ParentPath = []
04:18:54 T:2304 M:1185120256 DEBUG: thread start, auto delete: 0
04:18:54 T:2304 M:1185107968 WARNING: XFILE::CFileFactory::CreateLoader - Unsupported protocol(addons) in addons://sources/executable/folder.jpg
04:18:54 T:2304 M:1185103872 DEBUG: Thread 2304 terminating
04:18:56 T:2940 M:1185320960 DEBUG: SDLKeyboard: scancode: 28, sym: 13, unicode: 13, modifier: 0
04:18:56 T:2940 M:1185320960 DEBUG: CApplication::OnKey: 61453 pressed, action is Select
04:18:56 T:2940 M:1185296384 DEBUG: CGUIMediaWindow::GetDirectory (addons://sources/executable/)
04:18:56 T:2940 M:1185296384 DEBUG: ParentPath = []
04:18:56 T:4292 M:1188950016 DEBUG: thread start, auto delete: 0
04:18:56 T:4292 M:1188945920 DEBUG: Thread 4292 terminating
04:18:56 T:4536 M:1188941824 DEBUG: CTextureCache::GetImageHash - unable to stat url C:\Documents and Settings\Admin\Application Data\XBMC\addons\script.games.rom.collection.browser\fanart.jpg
04:18:56 T:4536 M:1188941824 DEBUG: msg: PICTURE::LoadImage: Unable to open image: C:\Documents and Settings\Admin\Application Data\XBMC\addons\script.games.rom.collection.browser\fanart.jpg Error: (2)
04:18:56 T:4536 M:1188941824 ERROR: Texture manager unable to load file: C:\Documents and Settings\Admin\Application Data\XBMC\addons\script.games.rom.collection.browser\fanart.jpg
04:18:57 T:2940 M:1188810752 INFO: XCURL:Big GrinllLibCurlGlobal::CheckIdle - Closing session to http://www.joystiq.com (easy=050B9520, multi=00368080)
04:18:57 T:2940 M:1188855808 INFO: XCURL:Big GrinllLibCurlGlobal::CheckIdle - Closing session to http://api.themoviedb.org (easy=050D99B0, multi=050D8488)
04:18:58 T:2940 M:1189011456 DEBUG: SDLKeyboard: scancode: 23, sym: 105, unicode: 105, modifier: 0
04:18:58 T:2940 M:1189011456 DEBUG: CApplication::OnKey: 61513 pressed, action is info
04:19:00 T:2940 M:1188929536 INFO: XCURL:Big GrinllLibCurlGlobal::CheckIdle - Closing session to http://xoap.weather.com (easy=050C98C8, multi=050C8320)
04:19:01 T:2940 M:1189326848 DEBUG: SDLKeyboard: scancode: 46, sym: 99, unicode: 99, modifier: 0
04:19:01 T:2940 M:1189326848 DEBUG: CApplication::OnKey: 61507 pressed, action is ContextMenu
04:19:01 T:2940 M:1189326848 DEBUG: CFavourites::Load - no system favourites found, skipping
04:19:01 T:2940 M:1189318656 INFO: Loading skin file: DialogContextMenu.xml
04:19:01 T:2940 M:1189310464 DEBUG: ------ Window Init (DialogContextMenu.xml) ------
04:19:02 T:2940 M:1188388864 DEBUG: SDLKeyboard: scancode: 28, sym: 13, unicode: 13, modifier: 0
04:19:02 T:2940 M:1188388864 DEBUG: CApplication::OnKey: 61453 pressed, action is Select
04:19:02 T:2940 M:1188589568 DEBUG: ------ Window Deinit (DialogContextMenu.xml) ------
04:19:02 T:2940 M:1189113856 DEBUG: ------ Window Init (DialogAddonSettings.xml) ------
04:19:02 T:2940 M:1189113856 INFO: Loading skin file: DialogAddonSettings.xml

Anyone know why this is happening?


- malte - 2010-09-05

XBMCG33K Wrote:This error only happens when I try to configure the script

Sorry, configuration via settings dialog is not yet implemented in the current version. It has to be done via xml file (config.xml). You could try this with the config file in the test scenario or create your own one. A commented config file can be found in the scripts install dir RCB/resources/database/config.xml.

I would recommend to try the test scenario as a start.


- User 55003 - 2010-09-05

Great work Malte Big Grin Thought I'd finally have a good look at this one, and I'm gald I did, bit of a read Wink but thats cool..
Had a few probs 2 start, but worked them out.. got mame and sega working without a prob Smile
Cheers!


- TioSolid - 2010-09-05

malte Wrote:
TioSolid Wrote:Does RCB support .dat files in any way? I think supporting these kind of files (from clrmamepro for example) would pretty much solve all the description problems for almost every console.
They are xml files, or? Not in the current version but this is the feature that I am working on atm. If this is done there will be a configurable way to import different xml formats. I think this .dat should work also.

But I am not sure if I can add these features step by step with some minor releases in between or if I have to throw a bomb in my code and have to wait a longer time before I can release a new version with xml (and scraping) support.

Yep, here is a snap of the MAME.dat file:
Code:
    <game name="ddsom" sourcefile="cps2.c">
        <description>Dungeons &amp; Dragons: Shadow over Mystara (Euro 960619)</description>
        <year>1996</year>
        <manufacturer>Capcom</manufacturer>
        <rom name="dd2e.03e" size="524288" crc="449361af" sha1="14af2b35e6f43f92c9e071f1dc85b18cf73ecb35"/>
        <rom name="dd2e.04e" size="524288" crc="5b7052b6" sha1="8a5f069f450da939d0f02518751cd9815d621d81"/>
        <rom name="dd2e.05e" size="524288" crc="788d5f60" sha1="b8b42c11530a34c2878fb119c0a388e33067b66d"/>
        <rom name="dd2e.06e" size="524288" crc="e0807e1e" sha1="4b978f5f647fff84d456eb14c9fd202d9a276997"/>
        <rom name="dd2e.07" size="524288" crc="bb777a02" sha1="4b2c65a9129fc2262b35be1c10d06f60f5108981"/>
        <rom name="dd2e.08" size="524288" crc="30970890" sha1="fd366a9323230f6997006ab4cc216f9a97865ebe"/>
        <rom name="dd2e.09" size="524288" crc="99e2194d" sha1="cbcecdf5beeac3eac6c2c3fa395710e1b8347531"/>
        <rom name="dd2e.10" size="524288" crc="e198805e" sha1="37ae9d88d98c59337b657cfa6feb56e4f9cae95f"/>
        <rom name="dd2.13m" size="4194304" crc="a46b4e6e" sha1="fb90f42868c581c481b4ceff9f692753fb186b30"/>
        <rom name="dd2.15m" size="4194304" crc="d5fc50fc" sha1="bc692f17b18bb47a724cd5152377cd5ccd6e184a"/>
        <rom name="dd2.17m" size="4194304" crc="837c0867" sha1="3d6db290a8f76299a23543f0ccf6a7905e1088ac"/>
        <rom name="dd2.19m" size="4194304" crc="bb0ec21c" sha1="e43ccc1cf63ccd2b504cc9fd701af849a7321914"/>
        <rom name="dd2.14m" size="2097152" crc="6d824ce2" sha1="0ccfe6c8a944937718e28a1a373b5822c7b7001b"/>
        <rom name="dd2.16m" size="2097152" crc="79682ae5" sha1="ee84f4791c29ce9e2bae06ba3ec47ff4d2cd7054"/>
        <rom name="dd2.18m" size="2097152" crc="acddd149" sha1="7f50de9b2d1cc733594c642be1804190519caffa"/>
        <rom name="dd2.20m" size="2097152" crc="117fb0c0" sha1="15c01fa1a71b6469b0e1bde0ce5835c5ff9d938c"/>
        <rom name="dd2.01" size="131072" crc="99d657e5" sha1="1528dd6b07a0e79951a35c0457c8a9c9770e9c78"/>
        <rom name="dd2.02" size="131072" crc="117a3824" sha1="14f3a12170b601c5466c93af9d2f24e0b386b4e4"/>
        <rom name="dd2.11m" size="2097152" crc="98d0c325" sha1="7406e8d943d77c468eb418c4113261f4ab973bbf"/>
        <rom name="dd2.12m" size="2097152" crc="5ea2e7fa" sha1="0e6a9fd007f637adcb2226c902394f07de45e803"/>
    </game>

It does have most of the info (publisher, game name and rom file name) so it would be great if those files were supported.

If you need, you can get some dat files here: http://www.logiqx.com/Dats/


- Tomkun - 2010-09-06

malte Wrote:Will be no big thing. But %GAME% is really the game name that is displayed as title in RCB. So this may be "Legend of Zelda: Link to the past" or something like this (containing characters that are not allowed in file names). I have an item like this on my list for a long time (handling per game configurations) but until now no good idea how to do this. Adding %GAME% placeholder could be a start but I think it will run into problems in some situations.

Hmmm, OK. I understand what you are saying about the filenames, but how then does it work for artwork?


- TioSolid - 2010-09-06

Tomkun Wrote:Hmmm, OK. I understand what you are saying about the filenames, but how then does it work for artwork?

Afaik most artwork sets comes named using the filename of the game, not the name itself. Is it possible to use the filename for that instead of the game name?


- Tomkun - 2010-09-06

TioSolid Wrote:Afaik most artwork sets comes named using the filename of the game, not the name itself. Is it possible to use the filename for that instead of the game name?

That's what I mean...

%GAME%.png works for the artwork, so surely must be using the filename rather than the 'real' name.


- malte - 2010-09-06

@Steveb: Nice to hear. Thanks a lot!

Tomkun Wrote:%GAME%.png works for the artwork, so surely must be using the filename rather than the 'real' name.

Yes and no. On importing artwork I try both, filename and gamename (and additionally the foldername). But when I import artwork I know the full path of the artwork and I know that there must be a file with this name. So I can check what is the correct %GAME% placeholder.

Configuration files inside a command line can be used differently in all emus. I can't do a reliable check if I am using the correct placeholder. To get this working more reliable I guess I have to add some extra logic to handle config files.


- Tomkun - 2010-09-06

malte Wrote:@Steveb: Nice to hear. Thanks a lot!



Yes and no. On importing artwork I try both, filename and gamename (and additionally the foldername). But when I import artwork I know the full path of the artwork and I know that there must be a file with this name. So I can check what is the correct %GAME% placeholder.

Configuration files inside a command line can be used differently in all emus. I can't do a reliable check if I am using the correct placeholder. To get this working more reliable I guess I have to add some extra logic to handle config files.

Could you not add another tag which just uses the filename (sans extension)?

By the way, I'm sorry to keep bugging you with requests, but this script is so close to being perfect!


- malte - 2010-09-08

@Tomkun:
Yes, that could be a way to do this. I will add it on my list.


@all: Is anybody else able to reproduce this config.xml modification time bug (RCB asks you to import settings at every startup because it thinks config.xml was modified)? I need some log files (with INFO logging turned on) when this happens. I can't reproduce this error here.

If you can reproduce this error please do the following:

- Edit config.xml and set RCBSettings/logLevel to INFO
- Start RCB and import settings
- Restart RCB
- post the xbmc.log of the second run (the log should contain a line like this: "lastConfigChange from DB (as int):")

This is the last issue that stops me to submit 0.6.1 to the repo.


- Flomaster - 2010-09-08

I will have to grab that bug log when I get home, because it happens with me every time I open RCB

-=jason=-


- glindsey - 2010-09-09

I'm running into one unfortunate error... if I'm using the Alaska skin, all of the text in RCB is black and therefore invisible! If I get the time I'll make an Alaska skin for RCB, but in the meantime is there anything I can do short of switching back to the Confluence skin? My wife really loves Alaska!