It is currently March 28th, 2024, 1:26 pm

MusicBee state not updating

Get help with creating, editing & fixing problems with skins
Post Reply
Azthenix
Posts: 8
Joined: May 25th, 2020, 9:52 am

MusicBee state not updating

Post by Azthenix »

Edit: Nevermind, I'm just stupid

I am having trouble with musicbee state that should change when I play or pause the track, but it's stuck on state "0".

The image of a play button should change into a pause button when I click on it and vice versa.

Here is a small snippet of my project

Code: Select all

[Rainmeter]
Update=1000
Background="Player/bg.png"
BackgroundMode=3
BackgroundMargins=14,30,14,14

[MeasurePlayer]
Measure=NowPlaying
PlayerName=CAD
PlayerType=TITLE

[MeasureState]
Measure=Plugin
Plugin=NowPlaying
PlayerName=#PlayerName#
PlayerType=STATE
Substitute="0":"Play","1":"Pause","2":"Play"

[MeterPlay]
Meter=Image
MeasureName=MeasureState
ImageName="Player/%1.png"
X=60r
Y=-12r
LeftMouseUpAction=[!CommandMeasure "MeasurePlayer" "PlayPause"]
Azthenix
Posts: 8
Joined: May 25th, 2020, 9:52 am

Re: MusicBee state not updating

Post by Azthenix »

Thank you for the reference but I already found the problem after accidentally stumbling into the logs. On the [MeasureState], I forgot to change the #PlayerName# to MeasurePlayer.
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: MusicBee state not updating

Post by balala »

Azthenix wrote: May 25th, 2020, 12:56 pm On the [MeasureState], I forgot to change the #PlayerName# to MeasurePlayer.
No, to be precise, not to MeasurePlayer, but to [MeasurePlayer]. so the correct form of the option is not PlayerName=MeasurePlayer, but PlayerName=[MeasurePlayer].
Important difference.
Azthenix
Posts: 8
Joined: May 25th, 2020, 9:52 am

Re: MusicBee state not updating

Post by Azthenix »

balala wrote: May 25th, 2020, 6:25 pm No, to be precise, not to MeasurePlayer, but to [MeasurePlayer]. so the correct form of the option is not PlayerName=MeasurePlayer, but PlayerName=[MeasurePlayer].
Important difference.
Oh right, sorry for the typo.
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: MusicBee state not updating

Post by balala »

Azthenix wrote: May 26th, 2020, 2:19 am Oh right, sorry for the typo.
Alright if this is a typo, but if on your code you're losing the brackets, the measure doesn't work, so take care.
Post Reply