mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 3 1 2 3
#93558 10/08/04 11:51 PM
S
ShinZon
ShinZon
S
how can i do this:

@op nicks are blue and while talking their text is blue
+v nicks are green and while talking their colour is green

?

and one q more:

if Ops are blue, vops are green, uops are teal (by java applet)
what is colour of hops (i never saw it) if someone knows this too ?

Last edited by ShinZon; 10/08/04 11:53 PM.
#93559 11/08/04 12:11 AM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
on mIRC, hit Alt + B and then go to the Colors tab. Click on Add and choose the settings: color to highlight, modes, address, etc.. That should color the @Ops and +v as you want.

About the text coloring... I think using a script is the best way.
Code:
On *:TEXT:*:[color:red]#[/color]: {
 if ($nick isop [color:red]#[/color]) { echo 12 -mtbfl [color:red]#[/color] $+(<,$nick,>) $1- }
if ($nick isvoice [color:red]#[/color]) { echo 3 -mtbfl [color:red]#[/color] -mtbfl $chan $+(<,$nick,>) $1- }
}
This should work. Change the # to a specific channel if you wish to.

Hope it helps smile

Zyzzyx.

PS: Dont know about the halfop matter.

#93560 11/08/04 12:18 AM
S
ShinZon
ShinZon
S
can this with alt+b be done thru scripting somehow ?
(coz of themes)

and does this code that you gave me work if it is putted in alias or only in remotes ?

#93561 11/08/04 12:33 AM
A
alkahol1k
alkahol1k
A
i think this is what you are looking for:

alias mode1 {
if ($nick(#,$nick,r)) return
return $replace($left($nick)(#,$nick).pnick,1) ,+, +,@, @,%, %,., .)
}

this will color the mode but not the text


#93562 11/08/04 12:36 AM
A
alkahol1k
alkahol1k
A
just to break it down a bit more:

alias mode1 {
if ($nick(#,$nick,r)) return
return $replace($left($nick(#,$nick).pnick,1) ,+,+v,@,+o,%,+h,.,+q) <------ change the color on the second mode (+q,h,o,v)
}

#93563 11/08/04 12:41 AM
S
ShinZon
ShinZon
S
will this work on mirc 6.03 ?

#93564 11/08/04 12:48 AM
A
alkahol1k
alkahol1k
A
yup it should , i had it running way back on 5.91 i think.

on ^*:Text:*:#: { ech $chan [[ $+ $mode1 $+ / $+ text $+ / $+ $nick $+ ] $1- | halt }

i see:

[@/text/moo123] ty

#93565 11/08/04 12:54 AM
S
ShinZon
ShinZon
S
but in that alias i dont see FOR WHAT mode to set color and WHERE

can you pls give me 1 example, like for voice, just so i know for other modes

#93566 11/08/04 01:00 AM
A
alkahol1k
alkahol1k
A
try this

alias mode1 {
if ($nick(#,$nick,r)) return
return $replace($left($nick(#,$nick).pnick,1) ,+,3+,@,12@,%,13%,.,7.)
}

#93567 11/08/04 01:01 AM
L
LO_KEY
LO_KEY
L
you can use the /color command to change all colors avail in mIRC on the fly.....

an ex out of my script... (its in dialog so i hope u understand....)

Code:
 
 [color:red]
    did -a w 40 ACTION
    did -a w 40 BACKGROUND
    did -a w 40 CTCP
    did -a w 40 EDITBOX
    did -a w 40 EDITBOX TEXT
    did -a w 40 HIGHLIGHT
    did -a w 40 INACTIVE
    did -a w 40 INFO
    did -a w 40 INFO2
    did -a w 40 INVITE
    did -a w 40 JOIN
    did -a w 40 KICK
    did -a w 40 LISTBOX
    did -a w 40 MODE
    did -a w 40 NORMAL
    did -a w 40 NOTICE
    did -a w 40 NOTIFY
    did -a w 40 OTHER
    did -a w 40 OWN
    did -a w 40 PART
    did -a w 40 QUIT
    did -a w 40 TOPIC
    did -a w 40 WALLOPS
    did -a w 40 WHOIS
[/color]
 [color:green] 
if ($did($dname,40).seltext = $null) { did -d $dname $did 0 | did -u $dname $did | halt }
      if ($did($dname,$did).seltext = White) { color $did($dname,40).seltext 0 }
      if ($did($dname,$did).seltext = Black) { color $did($dname,40).seltext 1 }
      if ($did($dname,$did).seltext = Dark Blue) { color $did($dname,40).seltext 2 }
      if ($did($dname,$did).seltext = Green) { color $did($dname,40).seltext 3 }
      if ($did($dname,$did).seltext = Red) { color $did($dname,40).seltext 4 }
      if ($did($dname,$did).seltext = Brown) { color $did($dname,40).seltext 5 }
      if ($did($dname,$did).seltext = Purple) { color $did($dname,40).seltext 6 }
      if ($did($dname,$did).seltext = Orange) { color $did($dname,40).seltext 7 }
      if ($did($dname,$did).seltext = Yellow) { color $did($dname,40).seltext 8 }
      if ($did($dname,$did).seltext = Light Green) { color $did($dname,40).seltext 9 }
      if ($did($dname,$did).seltext = Teal) { color $did($dname,40).seltext 10 }
      if ($did($dname,$did).seltext = Light Blue) { color $did($dname,40).seltext 11 }
      if ($did($dname,$did).seltext = Blue) { color $did($dname,40).seltext 12 }
      if ($did($dname,$did).seltext = Violet) { color $did($dname,40).seltext 13 }
      if ($did($dname,$did).seltext = Grey) { color $did($dname,40).seltext 14 }
      if ($did($dname,$did).seltext = Light Grey) { color $did($dname,40).seltext 15 }
 [/color] 
 

[/color]
basically it boils down to:
color red option [color:green] colorcode

hope this helps. laugh

#93568 11/08/04 01:13 AM
S
ShinZon
ShinZon
S
well i get blue text from op
green from vop

[+/text/shinzon] sometext

but first "[" is black
and why this "/text/" is there ?
and on nicklist colors are not changing, why ?

#93569 11/08/04 01:15 AM
S
ShinZon
ShinZon
S
erm, thanks for help, but what i need is something different smile this colors can be changed thru mirc too =)
thanks anyway

Last edited by ShinZon; 11/08/04 01:15 AM.
#93570 11/08/04 01:15 AM
A
alkahol1k
alkahol1k
A
lol i thought you knew how to script, i'm not going to do it ALL for you i just gave you a very basic method that works. You can edit how you like.

#93571 11/08/04 01:18 AM
A
alkahol1k
alkahol1k
A
In an earlier post you wanted it to be done with scripting so thats what i did *shrugs*

#93572 11/08/04 01:19 AM
S
ShinZon
ShinZon
S
i know some basis, but these are more like mirc secret addons for me smirk

thanks anyway

#93573 11/08/04 04:18 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
(even though you two worked it out, I'm still going to answer what you asked me)

Yes, the Alt + B thing can be done via script. And the code I gave you should be put on Remotes. The next code should also be put in remotes. It will do what the Alt + B does.. it also contains an update to the earlier code I gave you, so its best if you put them in the same file.
Code:
on me:*:JOIN:[color:red]#[/color]: .timerCheckJoin 1 5 colormode $chan

alias ColorMode {
 :start
 if (!$ial) { who $1 | goto start }
 var %i = $nick ($1,0)
 while (%i) {
  if ($nick($1,%i) isop $1) { cline 12 $1 $nick($1,%i) }
  if ($nick($1,%i) isvoice $1) { cline 3 $1 $nick($1,%i) }
  dec %i
 }
}
This will color the nick in the nicklist: @'s and +'s. Paste it in the same file that the other code is in. If both codes are loaded, this should (not tested) color the nickname in the list, the nick in the channel message and the message itself.

Good luck!
Zyzzy smile

#93574 11/08/04 07:50 PM
S
ShinZon
ShinZon
S
Alkoholic1:
your code doesnt color nicks with modes in nicklist frown

Zyzzy:
your code freezes my mirc shocked

so i will make this the simple...
not to bother ppl with coding, new request needed:
just to colorise nicknames with @ % + (op, ho, vop)

but some code that will work ?
anyone who helps me in this will be my saviour !

#93575 11/08/04 10:32 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Code:
alias ColorMode {
 :start
 if (!%temp) { who $1 | goto start | inc -u30 %temp }
 var %i = $nick ($1,0)
 while (%i) {
  if ($nick($1,%i) isop $1) { cline 12 $1 $nick($1,%i) }
  if ($nick($1,%i) isvoice $1) { cline 3 $1 $nick($1,%i) }
  dec %i
 }
}
It was my mistake.. the $ial thingie wouldnt work. This should do it smile

#93576 11/08/04 10:36 PM
S
ShinZon
ShinZon
S
i tested this on clean mirc 6.03

nothing is changed or Oped nick and voped nick
and on /hop and /join i got exces flood kill

Last edited by ShinZon; 11/08/04 10:38 PM.
#93577 11/08/04 10:53 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Im such a stupid guy! var %i = %nick_($1,0) <- that space doesnt exist! :P That was causing the excess flood

Try this code, it will work when you join a channel
Code:
raw 366:*: {
  var %i = $nick($2,0)
  while (%i) {
    if ($nick($2,%i) isop $2) { cline 12 $2 $nick($2,%i) }
    if ($nick($2,%i) isvoice $2) { cline 3 $2 $nick($2,%i) }
    dec %i
  }
}
Sorry for the mistake!

Zyzzy smile

#93578 11/08/04 10:56 PM
S
ShinZon
ShinZon
S
thank you so very much !

#93579 11/08/04 11:02 PM
S
ShinZon
ShinZon
S
i know i bugg too much :P

but when a user is non mode, it is normal (default colored)
and when i vop him or op him, he dont changes color.

is it possible to change this ?

#93580 11/08/04 11:03 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
You're welcome smile If you use this code and that one I posted above, you will achieve what you wanted smile

Code I posted above:
Code:
On *:TEXT:*:#: {
 if ($nick isop #) { echo 12 -mtbfl # $+(&lt;,$nick,&gt;) $1- }
 if ($nick isvoice #) { echo 3 -mtbfl # -mtbfl $chan $+(&lt;,$nick,&gt;) $1- }
}


Have fun! smile
Zyzzy

#93581 11/08/04 11:06 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
yes smile You can either /hop the channel or add this code:

Code:
on *:OP:#: cline 12 # $opnick
on *:DEOP:#: cline 1 # $opnick
on *:VOICE:#: cline 3 # $vnick
on *:DEVOICE:#: cline 1 # $vnick
No bugs on this one, I hope wink

Zyzzyx smile

Last edited by Zyzzyx26; 11/08/04 11:07 PM.
#93582 11/08/04 11:32 PM
S
ShinZon
ShinZon
S
i have some problems here:

on *:OP:#: {
if ($opnick isvoice #) cline 12 # $opnick
if ($opnick ishop #) cline 12 # $opnick
else cline 12 # $opnick
}


on *:DEOP:#: {
if ($opnick isvoice #) cline 3 # $opnick
if ($opnick ishop #) cline 11 # $opnick
else cline 1 # $opnick
}

on *:VOICE:#: {
if ($vnick isop #) cline 12 # $vnick
if ($vnick ishop #) cline 11 # $vnick
else cline 3 # $vnick
}


on *:DEVOICE:#: {
if ($vnick isop #) cline 12 # $vnick
if ($vnick ishop #) cline 11 # $vnick
else cline 1 # $vnick
}


If nick is opped and i give him voice it become green altho in code it is specifited to stay blue, when i deop nick that is green it becomes black (default) even if it is voiced and it shoud be green

If nick is voiced, and then opped and i devoice him it stays opped with no color even it is specifited that stays blue

what is wrong here?

#93583 12/08/04 12:10 AM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Code:
on *:OP:#: cline 12 # $opnick
on *:DEOP:#: {
 if ($opnick ishop #) { cline 11 # $opnick }
 elseif ($opnick isvoice #) { cline 3 # $opnick }
 else { cline 1 # $opnick }
}
on *:VOICE:#: {
 if ($vnick ishop #) { cline 11 # $vnick }
 elseif ($vnick isop #) { cline 12 # $vnick }
 else { cline 3 # $vnick }
}
on *:DEVOICE:#: {
 if ($vnick ishop #) { cline 11 # $vnick }
 elseif ($vnick isop #) { cline 12 # $vnick }
 else { cline 1 # $vnick }
}
on *:HELP:#: {
 if ($hnick isop #) { cline 12 # $hnick }
 else { cline 11 # $hnick }
}
on *:DEHELP:#: {
 if ($hnick isop #) { cline 12 # $hnick }
 elseif ($hnick isvoice #) { cline 3 # $hnick }
 else { cline 1 # $hnick }
}
Hope this works smile

Zyzzy

#93584 12/08/04 01:13 AM
A
alkahol1k
alkahol1k
A
lol

i thought you only wanted it for the events you saw in the channel

#93585 12/08/04 03:19 AM
S
ShinZon
ShinZon
S
heeee it works perfect now !

just 1 tiny question...
since mirc cannot detect uop (user op) by default as $hnick $vnick, is it possible thru script to do it ?

if yes, how ?

#93586 12/08/04 07:46 AM
T
theRat
theRat
T
$nick(#,N/nick,aohvr,aohvr)
Returns Nth nickname in the channels nickname listbox on channel #.

Both aohvr parameters are optional. The first specifies which nicks you'd like included, and the second specifies the nicks you'd like excluded, where:
a = all nicks, o = ops, h = halfops, v = voiced, r = regular



but also other mode characters work


#93587 12/08/04 10:28 AM
S
ShinZon
ShinZon
S
so how would i include uop with this (above) code ?

if there is no such On UOP mode ?

#93588 12/08/04 04:40 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
I'm not sure of what you're talking about... what is UOP? Is it a user mode, like @ and +v?

If it is, you can use the on RAWMODE event.
I will use the letter q as the UOP letter, like o is @Op and v is +voice, but you must change the q's in red for the actual letter of the user mode
Code:
on *:RAWMODE:#: {
 var %modes = $remove($1,-,+)
 var %x = $numtok($2-,32)
 while (%x) {
  var %i = $len(%modes)
  while (%i) {
    if ([color:red]q[/color] == $mid(%modes,%i,1) &amp;&amp; ($left($1,1) == -) { 
    if ($gettok($2-,%i,32) isop $chan) { cline 12 # $gettok($2-,%i,32) }
    elseif ($gettok($2-,%x,32) ishop $chan) { cline 11 # $gettok($2-,%x,32) }
    elseif ($gettok($2-,%x,32) svoice $chan) { cline 3 # $gettok($2-,%x,32) }
    else { cline [color:blue]UOP Color[/color] # $gettok($2-,%x,32) }
    }
    if ([color:red]q[/color] == $mid(%modes,%i,1) &amp;&amp; ($left($1,1) == +) { 
   [color:green] ; I am assuming the UOP mode is a LOWER mode than OP
    ; but HIGHER than Half Op and voice[/color]
     if ($gettok($2-,%x,32) isop $chan) { cline 12 # $$gettok($2-,%x,32) } 
     else { cline [color:blue]UOP Color[/color] # $gettok($2-,%x,32) }
   }
   dec %i
  }
dec %x
 }
}    
This is not tested, so please let me know how it goes smile

Zyzzyx smile

Last edited by Zyzzyx26; 12/08/04 04:41 PM.
#93589 12/08/04 07:15 PM
S
ShinZon
ShinZon
S
uop is lower than voice
so itz like this:

@ Op
% Hop
+ voice
- uop
normal user

so dunno what shloud be changed here coz you assumed itz above hop and vop

and i get error on this line:

"* /if: invalid format"

if (q == $mid(%modes,%i,1) && ($left($1,1) == -) {

Last edited by ShinZon; 12/08/04 08:14 PM.
#93590 12/08/04 08:17 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Then it should look like this:
Remember to change the q's for the actual UOP letter!!
Code:
on *:RAWMODE:#: {
 var %modes = $remove($1,-,+)
 var %x = $numtok($2-,32)
 while (%x) {
  var %i = $len(%modes)
  while (%i) {
    if ([color:red]q[/color] == $mid(%modes,%i,1) &amp;&amp; ($left($1,1) == -) { 
     if ($gettok($2-,%i,32) isop $chan) { cline 12 # $gettok($2-,%i,32) }
     elseif ($gettok($2-,%x,32) ishop $chan) { cline 11 # $gettok($2-,%x,32) }
     elseif ($gettok($2-,%x,32) isvoice $chan) { cline 3 # $gettok($2-,%x,32) }
     else { cline UOP Color # $gettok($2-,%x,32) }
    }
    if ([color:red]q[/color] == $mid(%modes,%i,1) &amp;&amp; ($left($1,1) == +) { 
      if ($gettok($2-,%x,32) isop $chan) { cline 12 # $$gettok($2-,%x,32) } 
      elseif ($gettok($2-,%x,32) ishop $chan) { cline 11 # $$gettok($2-,%x,32) } 
      elseif ($gettok($2-,%x,32) isvoice $chan) { cline 3 # $$gettok($2-,%x,32) }
      else { cline UOP Color # $gettok($2-,%x,32) }
    }
  dec %i
  }
dec %x
 }
}

And just out of curiosity.. what is UOP's letter? smile

Zyzzy

#93591 12/08/04 08:21 PM
S
ShinZon
ShinZon
S
/mode #chan +u nickname

so itz "u"

prefix is "-"

so in listbox itz

@nickname
%nickname
+nickname
-nickname

#93592 12/08/04 08:26 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Ok then, just replace those red q's for the u smile

#93593 12/08/04 08:27 PM
S
ShinZon
ShinZon
S
i stll get error here:

if (u == $mid(%modes,%i,1) && ($left($1,1) == -) {

i changed q to u
and added color 10 for uop and it wont color it into 10 but it stays as normal (white)


Last edited by ShinZon; 12/08/04 08:35 PM.
#93594 12/08/04 08:37 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
Code:
on *:RAWMODE:#: {
  var %modes = $remove($1,-,+)
  var %x = $numtok($2-,32)
  while (%x) {
    var %i = $len(%modes)
    while (%i) {
      if (u == $mid(%modes,%i,1)[color:red])[/color] &amp;&amp; ($left($1,1) == -) { 
        if ($gettok($2-,%i,32) isop $chan) { cline 12 # $gettok($2-,%i,32) }
        elseif ($gettok($2-,%x,32) ishop $chan) { cline 11 # $gettok($2-,%x,32) }
        elseif ($gettok($2-,%x,32) isvoice $chan) { cline 3 # $gettok($2-,%x,32) }
        else { cline 13 # $gettok($2-,%x,32) }
      }
      if (u == $mid(%modes,%i,1)[color:red])[/color] &amp;&amp; ($left($1,1) == +) { 
        if ($gettok($2-,%x,32) isop $chan) { cline 12 # $$gettok($2-,%x,32) } 
        elseif ($gettok($2-,%x,32) ishop $chan) { cline 11 # $$gettok($2-,%x,32) } 
        elseif ($gettok($2-,%x,32) isvoice $chan) { cline 3 # $$gettok($2-,%x,32) }
        else { cline [color:blue]1[/color] # $gettok($2-,%x,32) }
      }
      dec %i
    }
    dec %x
  }
}
There were 2 parentheses missing there :P Also, that 1 in blue should be there, instead of the UOP color. This code I'm almost sure it works laugh

Tell me if it does!
Zyzzy

#93595 12/08/04 08:42 PM
S
ShinZon
ShinZon
S
combined with /names raw and ON deop, help, voice... events it works, BUT since uop doesn thave ON UOP event, while having uop mode and opped or voiced, then deoped or devoiced instead uop color it returns to normal color

is it possible to make ON event for UOP too ?

#93596 12/08/04 09:02 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
No, its not possible to create an on UOP mode. The on Rawmode is the best you can have.

This code by starbucks mafia might help you! smile

Good luck!

Zyzzyx.

#93597 12/08/04 09:18 PM
S
ShinZon
ShinZon
S
i thank you very very much for helping me in this !

add: is it possible then just to detect preffix infront of nickname
like:

on deop IF + is infront then do something ?

Last edited by ShinZon; 12/08/04 09:19 PM.
#93598 12/08/04 09:26 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
on *:DEOP:#: if (+ isin $nick(#,$opnick).pnick) { commands }
on *:DEVOICE:#: if (@ isin $nick(#,$opnick).pnick) { commands }

This might help smile

#93599 12/08/04 09:35 PM
S
ShinZon
ShinZon
S
well i tried this

on *:DEOP:#: {
if (- isin $nick(#,$opnick).pnick) { cline 10 # $opnick }
if ($opnick ishop #) { cline 11 # $opnick }
elseif ($opnick isvoice #) { cline 3 # $opnick }
else { cline 0 # $opnick }
}

so if nick has uop and on deop that it doesnt lose uop color, but it still does...

any idea how to make this event work ?

#93600 12/08/04 10:09 PM
Joined: Feb 2004
Posts: 714
Z
Hoopy frood
Offline
Hoopy frood
Z
Joined: Feb 2004
Posts: 714
if (- isin $nick(#,$opnick).pnick) { cline 10 # $opnick }
Here you color the nick if they are UOP

if ($opnick ishop #) { cline 11 # $opnick }
Here you color the nick again if they are Hop (so the UOP color wont show)

elseif ($opnick isvoice #) { cline 3 # $opnick }
Here you say that, if the person is not an Hop AND they are a voice, color the nick again.

else { cline 0 # $opnick }
If the nick is not an Hop, not a voice and not an UOP, color them white.

So, if they are UOP but also are +voice or %hop, the Uop color will be overwrited.

Another thing, the character - is very used in nickname, so i suggest you to replace this line: if (- isin $nick(#,$opnick).pnick) { cline 10 # $opnick } for this one:
Code:
if (- isin $remove($nick(#,$opnick).pnick,$opnick)) { cline 10 # $opnick }

Hope it works smile


#93601 12/08/04 11:38 PM
S
ShinZon
ShinZon
S
thanks again for everything !

Page 1 of 3 1 2 3

Link Copied to Clipboard