Dies ist eine alte Version des Dokuments!


ColorRemove

Durch das Script werden Farbige Texte in Channels mit der ausgewählten Standardfarbe angezeigt.

#NewScriptBegin ColorRemove
 
Sub Chan_Msg(Text, Nick, Channel, FrameID, ConnID)
i=1
wri=0
do
  if asc(mid(Text, i, 1))=3 or asc(mid(Text, i, 1))=3 Then
    if (len(Text)-i)<5 Then 
      Text= Text + String(5, " ")
    End if    
    Text=left(Text, (i-1)) & remcoldigs(right(left(Text, (i+5)),5)) & right(Text,(len(Text)-i-5))
    i=i-1
    wri=1
    SkipEvent  
  End if
  i=i+1
loop until i>=len(Text)
if wri = 1 Then
  if Instr(1, Text, GetVal(ConnID, 5))>0 Then
    SetLineIcon FrameID, 0
    SetFrameIcon FrameID, 3
    SetTrayIcon 4
  End if
  SetFrameIcon FrameID, 2
  if Instr(1, left(Text, 7), Chr(1) & "ACTION")=1 Then
    print "* " & Nick , FrameID , valcText
    print Right(Text, len(Text)-7) , FrameID , valcText,  1
  else
    print "<" & Nick & ">" , FrameID , valcSender
    print Text , FrameID , valcText,  1
  End if
End if
End Sub
Sub remcoldigs(Text)
  if (asc(Text)<58 and asc(Text)>47) Then
     Text=right(Text, (len(Text)-1))
  End if
  if (asc(Text)<58 and asc(Text)>47) Then
     Text=right(Text, (len(Text)-1))
  End if 
  if left(Text, 1) = "," Then
    if (asc(mid(Text, 2, 1))<58 and asc(mid(Text, 2, 1))>47) Then              
      Text=right(Text, (len(Text)-2))
      if (asc(left(Text, 1) )<58 and asc(left(Text, 1))>47) Then
        Text=right(Text, (len(Text)-1))
      End if
    End if
  End if
  remcoldigs=Text
End Sub

Eigene Werkzeuge