Author Topic: Play random episode of a show in XBMC  (Read 14025 times)

0 Members and 1 Guest are viewing this topic.

fattybunter

  • $upporter
  • Contributor
  • *****
  • Posts: 57
  • Karma: 0
    • View Profile
Re: Play random episode of a show in XBMC
« Reply #15 on: January 30, 2013, 11:41:56 PM »
James-

I've just installed Frodo XBMC & Vox and have been updating everything accordingly.  I see that you included a "Random Episodes of {1}" in the XBMC TV folder that generates a nice playlist and loads it up.  This is great, but not quite what I had before. 

In the previous version f Vox/XBMC I have it set up to say "Play X episodes of X" and it automatically plays however many specified episodes back-to-back.  Without too much work, do you know of a way to modify your code to do this?

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7713
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Play random episode of a show in XBMC
« Reply #16 on: January 31, 2013, 08:52:44 AM »
I think I could probably figure it out, but it would help a lot if you could upload the XML for your old command so I can see exactly how it worked on eden.

You can just right click the command in the tree and copy it, then paste it into a forum post.  Thanks

fattybunter

  • $upporter
  • Contributor
  • *****
  • Posts: 57
  • Karma: 0
    • View Profile
Re: Play random episode of a show in XBMC
« Reply #17 on: February 02, 2013, 05:22:52 PM »
The main tree is here:

Code: [Select]
<?xml version="1.0" encoding="utf-16"?>
<command id="292" name="Play random episodes of" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
  <action>
    <cmdType>XBMC.LoadSmart</cmdType>
    <cmdString>smarts\randomepisodes.xsp</cmdString>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>XBMC.ExecBuiltin</cmdType>
    <cmdString>Playmedia({path.vc}\VoxSmart.xsp)</cmdString>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <phrase>play</phrase>
  <payloadFromXML phraseOnly="False" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone">a1ep.xml</payloadFromXML>
  <phrase optional="true">episodes, episode</phrase>
  <phrase optional="true">random</phrase>
  <phrase optional="true">episodes of, episode of</phrase>
  <payloadFromXML phraseOnly="True" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone">XbmcPayloads\xbmcTvShowTitles.xml</payloadFromXML>
</command>

And the a1ep.xml is here:

Code: [Select]
<?xml version="1.0" encoding="utf-8"?>
<!--A VoxCommando Payload file-->
<PayloadsRoot>
    <payload>
        <value>1</value>
        <phrase>a,an,1</phrase>
    </payload>
    <payload>
        <value>2</value>
        <phrase>2</phrase>
    </payload>
    <payload>
        <value>3</value>
        <phrase>3</phrase>
    </payload>
    <payload>
        <value>4</value>
        <phrase>4</phrase>
    </payload>
    <payload>
        <value>5</value>
        <phrase>5</phrase>
    </payload>
    <payload>
        <value>6</value>
        <phrase>6</phrase>
    </payload>
    <payload>
        <value>7</value>
        <phrase>7</phrase>
    </payload>
    <payload>
        <value>8</value>
        <phrase>8</phrase>
    </payload>
    <payload>
        <value>9</value>
        <phrase>9</phrase>
    </payload>
    <payload>
        <value>10</value>
        <phrase>10</phrase>
    </payload>
    <payload>
        <value>11</value>
        <phrase>11</phrase>
    </payload>
    <payload>
        <value>12</value>
        <phrase>12</phrase>
    </payload>
    <payload>
        <value>13</value>
        <phrase>13</phrase>
    </payload>
    <payload>
        <value>14</value>
        <phrase>14</phrase>
    </payload>
    <payload>
        <value>15</value>
        <phrase>15</phrase>
    </payload>
    <payload>
        <value>16</value>
        <phrase>16</phrase>
    </payload>
    <payload>
        <value>17</value>
        <phrase>17</phrase>
    </payload>
    <payload>
        <value>18</value>
        <phrase>18</phrase>
    </payload>
    <payload>
        <value>19</value>
        <phrase>19</phrase>
    </payload>
    <payload>
        <value>20</value>
        <phrase>20</phrase>
    </payload>
</PayloadsRoot>

Thanks again for helping out.  Hopefully other people will benefit from this as well.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7713
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Play random episode of a show in XBMC
« Reply #18 on: February 02, 2013, 06:11:06 PM »
OK.

You need to put the attached playlist in your VC\smarts folder

Here is the command:

Code: [Select]
<?xml version="1.0" encoding="utf-16"?>
<command id="292" name="Play {1} random episodes of {2}" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
  <action>
    <cmdType>XJson.SmartPL</cmdType>
    <cmdString>smarts\playXrandomepisodesofY.xsp&amp;&amp;{1}&amp;&amp;{2}</cmdString>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>XJson.Raw</cmdType>
    <cmdString>Player.Open&amp;&amp;"item":{"file":"special://profile/playlists/mixed/voxsmart.xsp"}, "options": { "shuffled": true}</cmdString>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <phrase>play</phrase>
  <payloadFromXML phraseOnly="False" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone">payloads\a1ep.xml</payloadFromXML>
  <phrase optional="true">episodes, episode</phrase>
  <phrase optional="true">random</phrase>
  <phrase optional="true">episodes of, episode of</phrase>
  <payloadFromXML phraseOnly="True" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone">XbmcPayloads\xbmcTvShowTitles.xml</payloadFromXML>
</command>

fattybunter

  • $upporter
  • Contributor
  • *****
  • Posts: 57
  • Karma: 0
    • View Profile
Re: Play random episode of a show in XBMC
« Reply #19 on: February 02, 2013, 07:55:21 PM »
Worked like a charm.  Thank you sir