Here's the relevant portion for the Rating:
- Code: Select all
sub rate {
grab_song();
use Net::DBus qw(:typing);
# Rate and announce.
$newrating = dbus_int32(@_);
$iface->SetPlayingRating($newrating);
Xchat::print("Rated $track by $artist a $newrating/$maxrating.");
return 1;
}
grab_song is a subroutine that sets a lot of vars related to the song in question.
Now, this portion of the code only KIND OF works. You see, regardless of whatever I type in, it ALWAYS sets the new rating to 5 via DBUS.
Any ideas?