{ CONFIGURATION } {==================================================} const bannertext_file = 'C:\Program Files\SpacialAudio\SAMBC\PAL\BannerText.txt'; const change_interval = '+00:10:00'; {==================================================} { IMPLEMENTATION } {--------------------------------------------------} var CurSong : TSongInfo; var UpdSong : TSongInfo; var Banners : TStringList; var Toggle : Boolean = True; var LinePos : Integer = 0; {Set this script to restart itself} PAL.Loop := True; { Create some objects that we will need} UpdSong := TSongInfo.Create; Banners := TStringList.Create; { Load banner lines into stringlist object } if FileExists(bannertext_file) then Banners.LoadFromFile(bannertext_file) else WriteLn('Banner source file does not exist!'); LinePos := 0; while (LinePos<Banners.Count) do begin {Wait for specified time} PAL.WaitForTime(change_interval); {Retrieve the current banner line and assign it to song object} UpdSong['title'] := Banners[LinePos]; {Tell encoders to update song information: When Toggle is True, we use the normal song information from the active player - otherwise we use our banner song object } Toggle := not Toggle; if Toggle then begin CurSong := ActivePlayer.GetSongInfo; Encoders.SongChange(CurSong); CurSong.Free; end else Encoders.SongChange(UpdSong); {Move to the next line in the banner file before we continue} LinePos := LinePos + 1; end; {Destroy objects once we no longer need them} Banners.Free; UpdSong.Free; {--------------------------------------------------}
var P : TPlayer; var Song : TSongInfo; var strFile, strPath, strJingle : String; var i : integer; PAL.Loop := True; i := ActivePlayer.GetVolume; P := SoundFX; strPath := 'C:\CLOCK\'; //путь к папке с отбивкой PAL.WaitForTime('XX:59:45'); //запускаемся в конце каждого часа strFile := strPath + FormatDateTime('hh', now+1/24) + '-00.mp3'; Queue.AddFile(strFile, ipTop); Song := Queue.NextInQueue; P.QueueSong(Song); ActivePlayer.Volume := i - 40; ActivePlayer.Volume := i - 80; ActivePlayer.Volume := i - 120; ActivePlayer.Volume := i - 160; P.Play; PAL.WaitForTime('+00:00:03'); ActivePlayer.Volume := i - 160; ActivePlayer.Volume := i - 120; ActivePlayer.Volume := i - 80; ActivePlayer.Volume := i - 40; ActivePlayer.Volume := i;
var Song : TSongInfo; //скрипт будет выполнятся постоянно(многократно) PAL.Loop := True; //ставим задержку на 30 минут PAL.WaitForTime('+02:44:00'); //выбираем трек наугад Song := CAT['Promos (All)'].ChooseSong(smRandom,NoRules); //добавляем его в начало очереди Queue.Add(song,ipTop);
var D : TDataSet; D := QUERY('SELECT * FROM songlist',[],True); PAL.LockExecution; D.First; while not D.EOF do begin if not FileExists(D['filename']) then begin WriteLn('Removing '+D['filename']); ExecSQL('DELETE FROM songlist WHERE ID = :ID',[D['ID']]); ExecSQL('DELETE FROM categorylist WHERE songID = :ID',[D['ID']]); end; D.Next; end; PAL.UnLockExecution;
var mySong : TSongInfo; //создаем переменную для обращение к деке PAL.Loop := True; //зацикливаем скрипт if (deckA.Status=1) and (deckB.Status=1) then //проверяем играет ли что нибудь в деках begin mySong := Cat['Music New'].ChooseSong(smRandom, noRules); //присваеваем случайный трек из категории mp3 в нашу переменную deckA.QueueSong(mySong); //запихиваем наш трек в деку deckA.Play; //запускаем деку CAT['Music New'].QueueBottom(smLemmingLogic, NoRules); //выбираем случайный трек из категории mp3 и кидаем в список следущих end;
<form method="POST" action="playlist.php"> <p>Поиск по названию песни:<br> <? InputText("search",$search,'',20); ?> <input type="submit" value=" Найти " name="B1"><br /> <?php echo "Поиск по исполнителю:<br>"; for ($i=ord('0'); $i<=ord('Z'); $i++) echo '<a href="search2.php?letter='.$i.'">'.chr($i).'</a>'; echo "<br />"; for ($i=ord('А'); $i<=ord('Я'); $i++) echo '<a href="search2.php?letter='.$i.'">'.chr($i).'</a>'; ?> <br />Выводить по <? InputCombo("limit",$limit,25,'5,10,25,50,100'); ?> найденных результатов </p> </form>
var D : TDataSet; var P : TPlayer; var Song : TSongInfo; var S : TSongInfo; PAL.Loop := true; procedure pause(); begin PAL.WaitForTime ('+00:00:07'); end; S:=TSongInfo.Create; P:= ActivePlayer; Song := P.GetSongInfo; S['artist'] := ''; S['duration'] := 0; S['title'] := 'Трек: ' + Song['artist'] + ' - ' + Song['title']; Encoders.SongChange(S); PAL.WaitForTime ('+00:00:10'); if song['requestid'] > 0 then D := Query('SELECT * FROM requestlist WHERE ID = :J AND SongID = :I',[Song['requestID'],Song['ID']],true); if D['name'] <> '' then begin S['artist'] := ''; S['title'] := 'От кого: '+D['name']; S['duration'] := 0; Encoders.SongChange(S); PAL.WaitForTime ('+00:00:20'); pause(); end; if D['msg'] <> '' then begin S['artist'] := ''; S['title'] := 'Текст: '+D['msg']; S['duration'] := 0; Encoders.SongChange(S); PAL.WaitForTime ('+00:00:20'); pause(); pause(); end; D.Free; P.Free; Song.Free;