2011-07-11, 01:50
Method007 Wrote:I've seen this line:
<setting id="trailer_count" value="6" />
And i've tried adjusting it to a larger number, but it ends up just turning off the movie trailer functionality. Anybody got any ideas what part of the xml to edit to get it to play more then 10 trailers?
That is because the script does not understand anything greater than 6. How it breaks down is the following:
0 - None
1 - 1
2 - 2
3 - 3
4 - 4
5 - 5
6 - 10
as these are the options in settings.xml(the one in the script.cinema.experience/resources/ folder) There isn't an area to change in the settings.xml to get more than 10 trailers, the script would need to be changed. To get more trailers, you need to change code in the 'xbmcscript_player.py' file(lines 270-276)
original code:
Code:
xbmc.log( "[script.cinema.experience] - Retriving Trailers: %s Trailers" % (0, 1, 2, 3, 4, 5, 10,)[ int( _S_( "trailer_count" ) ) ],level=xbmc.LOGNOTICE )
trailers = _get_trailers( items=( 0, 1, 2, 3, 4, 5, 10, )[ int( _S_( "trailer_count" ) ) ],
mpaa=equivalent_mpaa,
genre=genre,
movie=movie,
mode = "playlist"
)
you notice the sequence( 0, 1, 2, 3, 4, 5, 10,)? if you change these values to different numbers(for instance ( 0, 2, 4, 8, 16, 32, 64,) you will get different number of trailers. So, with the above instance, a <setting id="trailer_count" value="6" /> would give you 64 trailers. Both lines should have the same sequence(the first one is for logging, the second one is for the retrieval of the trailers)