Changing color using conditionals in BBCODE isn't work

if I want to change color by syllabe using BBCODE isn't work if I put it inside of IF ( conditional ) example

I want to change color of NIKE , the first syllabe in vibrant color of album cover and the other using muted color of albumcover

$if(mi(state)=PLAYING, [c=bp(vibrant),mi(cover))]NI[/c],[c=bp(muted),mi(cover))]KE[/c])$

even if I use $if(mi(state)=PLAYING, [c=$bp(vibrant),mi(cover))$]NI[/c],[c=$bp(muted),mi(cover))$]KE[/c])$

but if you only use BBCODE without conditional it's work like a charm but using $ like this

[c=$bp(vibrant),mi(cover))$]NI[/c] this works but I need use the conditional.

Is a bug or what is it?

Oh well, I was testing and testing so I found other way to work this,

[c=$if(mi(state)=PLAYING,bp(vibrant,mi(cover)))$]text here[/c]

but I think this method is so long to implement per syllabe.

but BTW!!!

it Worked

Sorry I got worked the following example code, maybe this help someone in the earth.

This detect if your music player is playing then it verifies if the current track are Bob Marley, if Bob Marley then it change the BBcolor to RED else ISNOT bob marley then it will use the mute color of the coveralbum of the current track in BBCOLOR , then outside this the music player is stopped or paused then it put the white color of BBCODE

[c=$if(mi(state)=PLAYING,if(mi(artist)=Bob Marley,#FF0000,bp(muted, mi(cover))),#FFFFFFF)$]test music[/c]

Thanks and sorry for the delay, marking this as answered :)

The generic point is that BB code should NOT used inside formulas :)

Thanks Frank!!!