We don't care so much if its a bit out of sync by a few seconds here or there. It'll be really tough to make the timing perfect, we know.
Some thoughts after sleeping on it:
How do we get the title stream script to start at the same time as the rebroadcast file? Here's my idea. Put both scripts into one big PAL script, and have it tell SAM to "Queue.Clear;" load up the show file, and "Active Player.Fade To Next" the file currently in the player. Then the two functions we want would start within a few seconds of each other. I think so anyway.
But what about accounting for the times when the DJ is on mic? Is there any way that that occurrence can be shown in the history window? If so, then I can export that occurrence just like any other track, into a csv, or some other sort of file. I had thought of having the DJ use a silent music bed to talk over, as a sort of spacer, but it would show up in the history window with a duration of the entire silent track, not the amount of time the DJ was on mic, between the end of the last track and the beginning of the next. That would screw up the timing, and we're no better off.
I am also trying to think of a way to easily convert a csv file into lfsv format. I fiddled with it this morning with MS Excel, but had no luck, but then again, I'm a complete amateur when it comes to excel. I'll talk to my sister in law, who is a genius with excel, this weekend. Maybe she will have an idea.
Here's an example of the two scripts put together. Not tested, not compiled:
Code:
Cat['Reruns'].Clear;
Cat['Reruns'].AddDir('C:\Documents and Settings\Administrator\My Documents\My Music\Encores\SHOW XYZ', False, ipBottom);
Cat.Free;
Queue.Clear;
{then add the rerun file}
Cat['Reruns'].QueueBottom(smWeighted, NoRules);
{fade the currently playing song to start the rebroadcast}
ActivePlayer.FadeToNext;
{start the title stream script}
PAL.LockExecution;
var lfsv_file : String = 'C:\ 'C:\Documents and Settings\Administrator\My Documents\My Music\TITLE STREAMS\SHOW XYZ'.txt';
var song_info : TSongInfo = TSongInfo.Create;
var lfsv_info : TStringList = TStringList.Create;
var line_position : Integer = 0;
var artist, album, title, wait : String;
var can_run : Boolean = true;
if not FileExists( lfsv_file ) then
begin
WriteLn( 'LFSV file does not exist!' );
can_run := false;
end;
while ( can_run ) do
begin
lfsv_info.LoadFromFile( lfsv_file );
line_position := 0;
while ( line_position < lfsv_info.Count ) do
begin
artist := lfsv_info[ line_position ];
WriteLn( 'artist = ' + artist );
song_info[ 'artist' ] := artist;
line_position := line_position + 1;
album := lfsv_info[ line_position ];
WriteLn( 'album = ' + album );
song_info[ 'album' ] := album;
line_position := line_position + 1;
title := lfsv_info[ line_position ];
WriteLn( 'title = ' + title );
song_info[ 'title' ] := title;
line_position := line_position + 1;
//Encoders.SongChange( song_info );
wait := lfsv_info[ line_position ];
WriteLn( 'wait = ' + wait );
PAL.WaitForTime( '+' + wait );
line_position := line_position + 1;
WriteLn( '' );
end;
can_run := false;
end;
PAL.UnlockExecution;
lfsv_info.Free;
song_info.Free;