mIRC Home    About    Download    Register    News    Help

Print Thread
#150820 09/06/06 07:51 PM
Joined: Mar 2004
Posts: 155
D
Darkmnm Offline OP
Vogon poet
OP Offline
Vogon poet
D
Joined: Mar 2004
Posts: 155
Any advice or help would be greatly appreciated here. The thing I want to happen is when I play a song and it advertises in the channel what i am playing the line also say for a description of the song type !Desc and then it would notice the person but seems that for some reason it's not working. Below is the code that to me should work but doesn't seem to be doing so.

Code:
on *:TEXT:!Desc:*: {
  If ($insong) {
    If ($sound($insong.fname).artist) && ($sound($insong.fname).title) {
      .notice $nick 4,1  $+ $sound($insong.fname).artist $+ 's $sound($insong.fname).title $+ 
    }
    If (!$sound($insong.fname).artist) && (!$sound($insong.fname).title) {
      .notice $nick 4,1  $+ $nopath($replace($insong.fname,.mp3,$chr(32)))
    }
    If ($sound($insong.fname).album) {
      .notice $nick 4,1 Album: $sound($insong.fname).album $+ .
    }
    If (!$sound($insong.fname).album) {
      .notice $nick 4,1 Album: Not Specified.
    }
    If ($sound($insong.fname).genre) {
      .notice $nick 4,1 Genre: $sound($insong.fname).genre $+ .
    }
    If (!$sound($insong.fname).genre) {
      .notice $nick 4,1 Genre: Not Specified
    }
    If ($sound($insong.fname).year) {
      .notice $nick 4,1 Released Year $sound($insong.fname).year $+ .
    }
    If (!$sound($insong.fname).year) {
      .notice $nick 4,1 No Year Number Is Mentioned.
    }
    If (!$insong) { 
      .notice $nick 4,1No Song Is Currently Playing 
    }
  }
}

#150821 09/06/06 10:42 PM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
try this
Code:
on *:TEXT:!Desc:*: {
  If ($insong) {
    .notice $nick 4,1 $iif(($sound($insong.fname).title) && ($sound($insong.fname).artist), $sound($insong.fname).title by $sound($insong.fname).artist, Artist or Title not listed))
    .notice $nick 4,1 Album: $iif($insong.fname.album,$insong.fname.album $+ .,Not Specified. )
    .notice $nick 4,1 $iif($insong.fname.genre,Genre: $insong.fname.genre $+ .,Genre: Not Specified. )
    .notice $nick 4,1 Released Year: $iif($insong.fname.year,$insong.fname.year $+ .,No Year Number Is Mentioned. )
  }
  else { 
    .notice $nick 4,1 No Song Is Currently Playing 
  }
}

#150822 09/06/06 10:48 PM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
one line notice with info sorted by color
Code:
on *:TEXT:!Desc:*: {
  var %nick = .notice $nick
  If ($insong) {
    var %nick = %nick 4,1 $iif(($sound($insong.fname).title) && ($sound($insong.fname).artist), $sound($insong.fname).title by $sound($insong.fname).artist, Artist or Title not listed))
    var %nick = %nick 8Album: $iif($insong.fname.album,$insong.fname.album $+ .,Not Specified. )
    var %nick = %nick 4 $iif($insong.fname.genre,Genre: $insong.fname.genre $+ .,Genre: Not Specified. )
    var %nick = %nick 8 Released Year: $iif($insong.fname.year,$insong.fname.year $+ .,No Year Number Is Mentioned. )
  }
  else { 
    var %nick = %nick No Song Is Currently Playing 
  }
  %nick
}


Link Copied to Clipboard