[RELEASE] Advanced Launcher - Applications Launcher Addon for XBMC

  Thread Rating:
  • 15 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Angelscry Offline
Skilled Python Coder
Posts: 2,694
Joined: Sep 2010
Reputation: 37
Location: MTL, Canada
Post: #3581
(2012-06-26 20:35)chris295 Wrote:  Yeah, it's a files launcher, the same one I used with the AutoIt script, which loaded the games. All I did was switch the executable from the AutoIt Script to the .bat file so the path in Advanced Launcher should not have changed. The arguement is %rom%. Where would I find launchers.xml?

Sorry for putting you to all this trouble, I really appreciate the time you are taking to help me.
Ok... so if the argument is only %rom% and not "%rom%", then your script must be :

Code:
pssuspend "XBMC.exe"
pssuspend "Xpadder.exe"
"G:\XBMC\games\nes\nestopia.exe" "$1"
pssuspend -r "Xpadder.exe"
pssuspend -r "XBMC.exe"

Advanced Launcher | Manual | WiKi | Forums | Tutorials | Gallery | GitHub | Archives | Donate

(This post was last modified: 2012-06-26 20:51 by Angelscry.)
find quote
chris295 Offline
Member
Posts: 60
Joined: Jun 2012
Reputation: 0
Post: #3582
Sorry, it was "%rom%" not %rom%, I just forgot to mention the quotes

I had the $1 in the path without the quotation marks, but adding the quotes didn't seem to change anything.

I think this is what you wanted from the launcher xml

<launcher>
<id>5b8baf42646463f94f09e9e7bfeb40b6</id>
<name>NES</name>
<application>C:\Users\user\Desktop\nes.bat</application>
<args>"%rom%"</args>
<rompath>G:\XBMC\games\nes\roms\</rompath>
<thumbpath>G:\XBMC\games\nes\thumbnails\</thumbpath>
<fanartpath>G:\XBMC\games\nes\fanart\</fanartpath>
<custompath></custompath>
<romext>nes</romext>
<platform>Nintendo Entertainment System</platform>
<thumb>G:\XBMC\games\icons\List View\Nintendo_System_icon.png</thumb>
<fanart>G:\XBMC\games\icons\nes_fanart.jpg</fanart>
<genre>Hardware</genre>
<release>1985</release>
<publisher>Nintendo</publisher>
<launcherplot></launcherplot>
<finished>false</finished>
<minimize>true</minimize>
<lnk>true</lnk>
<roms>
<rom>

my current bat looks like this

pssuspend "XBMC.exe"
pssuspend "Xpadder.exe"
"G:\XBMC\games\nes\nestopia.exe" "$1"
pssuspend -r "Xpadder.exe"
pssuspend -r "XBMC.exe"

The only thing that was off was the quotations in the "$1" but I'm still getting the file missing error.
find quote
Angelscry Offline
Skilled Python Coder
Posts: 2,694
Joined: Sep 2010
Reputation: 37
Location: MTL, Canada
Post: #3583
(2012-06-26 20:58)chris295 Wrote:  Sorry, it was "%rom%" not %rom%, I just forgot to mention the quotes

I had the $1 in the path without the quotation marks, but adding the quotes didn't seem to change anything.

I think this is what you wanted from the launcher xml

<launcher>
<id>5b8baf42646463f94f09e9e7bfeb40b6</id>
<name>NES</name>
<application>C:\Users\user\Desktop\nes.bat</application>
<args>"%rom%"</args>
<rompath>G:\XBMC\games\nes\roms\</rompath>
<thumbpath>G:\XBMC\games\nes\thumbnails\</thumbpath>
<fanartpath>G:\XBMC\games\nes\fanart\</fanartpath>
<custompath></custompath>
<romext>nes</romext>
<platform>Nintendo Entertainment System</platform>
<thumb>G:\XBMC\games\icons\List View\Nintendo_System_icon.png</thumb>
<fanart>G:\XBMC\games\icons\nes_fanart.jpg</fanart>
<genre>Hardware</genre>
<release>1985</release>
<publisher>Nintendo</publisher>
<launcherplot></launcherplot>
<finished>false</finished>
<minimize>true</minimize>
<lnk>true</lnk>
<roms>
<rom>

my current bat looks like this

pssuspend "XBMC.exe"
pssuspend "Xpadder.exe"
"G:\XBMC\games\nes\nestopia.exe" "$1"
pssuspend -r "Xpadder.exe"
pssuspend -r "XBMC.exe"

The only thing that was off was the quotations in the "$1" but I'm still getting the file missing error.
Sorry... my mistake (too many computer language) :

Code:
pssuspend "XBMC.exe"
pssuspend "Xpadder.exe"
"G:\XBMC\games\nes\nestopia.exe" %1
pssuspend -r "Xpadder.exe"
pssuspend -r "XBMC.exe"

Advanced Launcher | Manual | WiKi | Forums | Tutorials | Gallery | GitHub | Archives | Donate

(This post was last modified: 2012-06-26 21:02 by Angelscry.)
find quote
chris295 Offline
Member
Posts: 60
Joined: Jun 2012
Reputation: 0
Post: #3584
Actually scratch that, that last mistake was mine, I forgot I changed the rom name a few minutes ago (thought maybe it was too long or something) it works with that %1 arguement. Can you explain what that %1 actually does for future knowledge? I don't want to bug you everytime I set something up with the launcher. Thanks so much!
(This post was last modified: 2012-06-26 21:12 by chris295.)
find quote
Angelscry Offline
Skilled Python Coder
Posts: 2,694
Joined: Sep 2010
Reputation: 37
Location: MTL, Canada
Post: #3585
(2012-06-26 21:05)chris295 Wrote:  Actually scratch that, that last mistake was mine, I forgot I changed the rom name a few minutes ago (thought maybe it was too long or something) it works with that %1 arguement. Can you explain what that %1 actually does for future knowledge? I don't want to bug you everytime I set something up with the launcher. Thanks so much!
%1 is referring to the first argument send to the .bat file. Advanced Launcher send all its argument field value to .bat files into %1. So if your command line to start your application is :

Code:
cd "C:\Program Files (x86)\Dolphin-x64-r6703\x64\Dolphin.exe" /b /e "%rom%"

And your Advanced launcher arguments are :

Code:
/b /e "%rom%"

Then the command line into your .bat file will be :

Code:
cd "C:\Program Files (x86)\Dolphin-x64-r6703\x64\Dolphin.exe" %1

But if your Advanced launcher arguments are only :

Code:
%rom%

Then the command line into your .bat file must be :

Code:
cd "C:\Program Files (x86)\Dolphin-x64-r6703\x64\Dolphin.exe" /b /e "%1"

Double quotes (") must be used around all paths to avoid problem with paths containing spaces. You also must take care to not use them in double because they cancel each other : double double quotes = no quote.

Advanced Launcher | Manual | WiKi | Forums | Tutorials | Gallery | GitHub | Archives | Donate

(This post was last modified: 2012-06-26 21:28 by Angelscry.)
find quote
chris295 Offline
Member
Posts: 60
Joined: Jun 2012
Reputation: 0
Post: #3586
I see, I guess that's why it didn't change anything when I added the quotes then.

Thanks so much for your help. The .bat does exactly what I want it to do now and thanks for Advanced Launcher too, it has to be the best XBMC add-on ever.
I just realized I forgot one other thing. Is it possible to kill a process with .bat file like it is with AutoIt? I was using the terminate function to exit programs launched from Advanced Launcher and binding it to the escape key but since I'm using a .bat now I have no idea how I'd go about that.
(This post was last modified: 2012-06-26 21:44 by chris295.)
find quote
Angelscry Offline
Skilled Python Coder
Posts: 2,694
Joined: Sep 2010
Reputation: 37
Location: MTL, Canada
Post: #3587
(2012-06-26 21:37)chris295 Wrote:  I just realized I forgot one other thing. Is it possible to kill a process with .bat file like it is with AutoIt? I was using the terminate function to exit programs launched from Advanced Launcher and binding it to the escape key but since I'm using a .bat now I have no idea how I'd go about that.
Not really simple to do this using .bat. Personnally I think it's more easy to do key control using autoit scripts. BTW, you can use the best of the 2 worlds. Here is an autoit script including previious .bat commands :

Code:
HotKeySet("{ESC}", "Terminate")

If $CmdLine[0] == 1 Then
    Run ( 'pssuspend "XBMC.exe"')
    Run ( 'pssuspend "Xpadder.exe"')
    Run ( '"G:\XBMC\games\nes\nestopia.exe" "' & $CmdLine[1] & '"', "G:\XBMC\games\nes\" )
    While 1
        Sleep(100)
    WEnd
EndIf

Func Terminate()
    ProcessClose ( "nestopia.exe" )
    Run ( 'pssuspend -r "Xpadder.exe"')
    Run ( 'pssuspend -r "XBMC.exe"')
    Exit 0
EndFunc

Advanced Launcher | Manual | WiKi | Forums | Tutorials | Gallery | GitHub | Archives | Donate

find quote
chris295 Offline
Member
Posts: 60
Joined: Jun 2012
Reputation: 0
Post: #3588
That last script is perfect. Thanks again!
find quote
gman3042 Offline
Senior Member
Posts: 298
Joined: Feb 2011
Reputation: 0
Post: #3589
ok... probably a noob question.. love this program.. my question is.. is there anyway an advanced launcher program can be launched by a keyboard shortcut? basically i want wmc live tv and recorded tv to start up the way it starts up for advanced launcher.. but by using my harmony remote in xbmc rather than navigating to the menu

any ideas?
find quote
Pissa Offline
Junior Member
Posts: 27
Joined: Jun 2012
Reputation: 0
Post: #3590
Hi guys!
I create different little batch files to close xbmc, start an external application, and after closing it automatically restart xbmc.
I found how to do it thanks to very useful post here and also on official advanced launcher forum.
I need to do this because my htpc has very weak hardware, so watching bluray with xbmc opened take away too much resources to my system. Killing xbmc, instead, allow me to watch them without any problem.
I have no problem with most of the batch for other app, but I cant't do it with PowerDVD12 (again, I know.... I saw a lot of old post about this software....)

XBMC closes, PowerDVD12 starts fine, but when closing it, XBMC doen't start again.
I think the problem it's because PowerDVD starts with PowerDVDlaunchPolicy.exe, but then the process running are:

PowerDVD.exe
PowerDVD12.exe
PowerDVD12Agent.exe
PowerDVD12DMREngine.exe
PowerDVD12ML.exe

Now the batch, very simple, is this:
Quote:pskill XBMC.exe
cd "C:\Program Files\CyberLink\PowerDVD12\"
PDVDLaunchPolicy.exe %1
cd "C:\Program Files\XBMC\"
start /max XBMC.exe

Someone can help me?! Wink
find quote
Post Reply