Support and General Use > Theming and Appearance Customization

Next track info when song is about to finish?

(1/1)

Elaphe:

I have seen this feature in a script but I have not been able to figure out how it works. I know how to display the next song title, but not how to make this work when there are only 15 seconds left for the song to finish. Also, I'd like to make the song title temporarily replacing the text of the track number, which is as follows in my theme:


--- Code: ---# Track number
%Vl(b,0,75,-,-,2) %Vf(ffffff) %Vb(000000)
%acTrack: %?in<%in|N/A>
--- End code ---

Can you help me modify this code for the function I want? Thanx.

[Saint]:

--- Code: ---%ac%s%?if(%pr,>,15)<Track: %?in<%in|N/A>|Next Track: %?It<%It|%Fn>>
--- End code ---

Pretty simple really. Lets break it down for you:

Center align all following text;
Scroll if we need to;
If current track time remaining is greater than 15s - show the current track number - else display the next track title;
If no next track title metadata is present, fall back to the next track file name.
End.


[Saint]

Elaphe:
Thank you very much.

I'm also trying with another idea: using timeouts to automatically switch between track number and next track title. However, I have the same problem as with other timeout I've tried for a graphic element: only one of the timeouts works with the specified time (9 seconds). The other one keeps on using 1 second.

Can you please take a look at the code. There must be something wrong. I don't really understand how to use < > | ; etc. so it's all trial and error for me until things start working. XD


--- Code: ---%acTrack: %?in<%in|N/A>;%t(9.0)%ac%sNext Track: %?It<%It|%Fn;%t(9.0)>
--- End code ---

Elaphe:
OK, I think I got it. It seems the timeouts must be placed before the item:


--- Code: ---# Track number
%Vl(b,0,75,-,-,2) %Vf(ffffff) %Vb(000000)
%ac%t(5.0)Track: %?in<%in|N/A>;%t(10.0)%ac%sNext: %?It<%It|%Fn>
--- End code ---

Navigation

[0] Message Index

Go to full version