Quick Sign In:  

Forum: VirtualDJ Skins

Topic: Skin value syntax question

Dieses Thema ist veraltet und kann veraltete oder falsche Informationen enthalten.

mcs1234PRO InfinityMember since 2010
Vers 8 Pro User using Hercules Black skin.
Have successfully added the bpm to my skin (scrolling, after song title) by adding "%bpm" after the "%title" line in the xml file.
Trying to add the "song length" to the %artist line because my skin only shows elapsed and remaining.
I'm guessing it would be "format= %artist %?????" to add song length.
Anyone know what the "%" syntax is for song length?
Thanks,
Doug
 

geposted Wed 05 Apr 17 @ 1:11 pm
The backtick/backquote in the skins xml file under format property will run vdj code so:
The following code will separate totaltime minutes and seconds with a colon

format="`get_totaltime_min`:`get_totaltime_sec`"


or like you asked to combine them with a space between the artist and the time
eq. Artist MM:SS


format= "%artist `get_totaltime_min`:`get_totaltime_sec`"


Though I'd probably put brackets around them
eq. Artist [MM:SS]


format= "%artist [`get_totaltime_min`:`get_totaltime_sec`]"


Side note: I personally like to use automix and use code like this to show the next songs title and total time:

format="Next Up: `get_automix_song 'title'` [`get_totaltime_min`:`get_totaltime_sec`]"


and thinking too if Virtual DJ Script could cook hamburgers and deliver them to my booth i'd add the following to my skin

format="`cook and deliver hamburger to my booth`" but hey can't a guy dream

 

geposted Wed 05 Apr 17 @ 5:10 pm
mcs1234PRO InfinityMember since 2010
Love that burger command! If only!!
Question: The code works ... BUT ... a song, whose 'seconds' are in the range "00" thru "09" - The code drops the leading zero.
Example: A song that is [5:09] in length displays as [5:9]. (no zero).
Do you know how to get the zero back?
Thanks!
 

geposted Wed 05 Apr 17 @ 7:57 pm
djdadPRO InfinityDevelopment ManagerMember since 2005
use the get_loaded_song to get whatever field you want from the track..
format= "%artist `get_loaded_song 'length'`"
 

geposted Wed 05 Apr 17 @ 8:25 pm
mcs1234PRO InfinityMember since 2010
Well, that works! Now how can I get that burger? :-)
Thanks all!!!
 

geposted Wed 05 Apr 17 @ 8:45 pm
 

geposted Wed 05 Apr 17 @ 8:50 pm
mcs1234PRO InfinityMember since 2010
If it's that easy, I may try to add rating in the scrolling info, too. Don't know if it will want "rating" or "stars" but I'll fiddle with it.
Love the ability to customize this stuff!
:-)
 

geposted Wed 05 Apr 17 @ 8:59 pm
Rating will return an integer from 0 to 5
Stars will return... stars! (from none to 5 stars in a sequence)
 

geposted Thu 06 Apr 17 @ 7:52 pm
mcs1234PRO InfinityMember since 2010
Cool. Thanks. I'll try it!
 

geposted Thu 06 Apr 17 @ 8:15 pm
mcs1234PRO InfinityMember since 2010
Oooh, that's even funner. (Even though "funner" isn't a word)...
:-)
Thanks.
 

geposted Thu 06 Apr 17 @ 8:27 pm


(Alte Themen und Foren werden automatisch geschlossen)