xport emu stuff
#1
hi,

i lately added support for the 'xport' way of sending params to programs from xbmc.

however, it is only accessible via shortcut .cut files.

example

<shortcut>
<path>f:\emulators\foo\bar.xbe</path>
<custom>
<game>d:\roms\foo.zip</game>
</custom>
</shortcut>

this can be used from python to create e.g. favorite rom scripts or whatever. basic example underneath (thanks donno)

Quote:import xbmc
import xbmcgui
import os
emu = "f:\\emulators\\xboyadvance\\default.xbe"
dir = "f:\\emulators\\xboyadvance\\gbaroms\\"
def savecut(name):
f = open("z:\\emu.cut","w")
d = "<shortcut><path>%s</path><custom><game>%s</game></custom></shortcut>" % (emu,name)
f.write(d)
f.close()

def checkdir(tdir):
dl = os.listdir(tdir)

ret = xbmcgui.dialog().select("choose rom",dl)

if os.path.isdir(tdir+dl[ret]):
checkdir(tdir+dl[ret])
else:
savecut(tdir+dl[ret])
xbmc.executebuiltin('xbmc.runxbe(z:\\emu.cut)')

checkdir(dir)

maybe somebody will find this useful..
Reply
#2
hum... i don't understand anything... can you explain a bit more ?
Reply
#3
basically what the script above does is gets a filelist (thou i was in a hurry so didn't know file extention filtering :d), and when u click the game it should create a 'cut' file in which the builtin command runxbe should launch the xport emulator and go straight into the game selected
** Team XBMC Tester** XBMC 4 ever

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#4
nice! hopefully someone will implement this into something useful.
Reply

Logout Mark Read Team Forum Stats Members Help
xport emu stuff0