mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
I have this set:
[cnicks]
n0=$me,7,,,1,1,0,0,0,0
n1=,99,,,1,1,0,1,0,1

I noticed some nicks randomly switch color during a chat, I have to restart mIRC to show the same colors again. Not sure it's a bug or whatever, just wanted Khaled to know about it.

I noticed maybe 3-4 times in months, it happens if I keep mIRC opened enough time.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
I think the color is based on a hash calculation against $address($nick,something), so if the nick identifies after joining the channel, then their address appears to change, and there's a good chance their color would also change.

Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
Eew. I would ask that Khaled consider associating random nick coloring to $ial().id which is a unique value associated to that user/connection for as long as mIRC sees them in at least one channel. If their address changes via `CAP chghost` their $ial().id remains the same. And only changes if the user /quits or /parts all channels in common with you.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
I think your issue is actually more related to mIRC discovering a person's user@host only after they speak at least once, because the server you are using does not support `CAP userhost-in-names` and so the colorization is initially based on their nickname only, but not their nickname!user@host. After time goes on and you learn more and more of their user@hosts across multiple channels they share in common with you, the act of parting-and-rejoining the channels, by either you or them, will cause you to see them wearing a different color.

Rather than restarting mIRC, you can use the command `/ialclear` or `/ialclear <nickname>` then rejoin those channels to reset the colors to be based in the user's nickname-only.

If you used `/ialfill <channel>` in all channels you're in, that would populate each chatter's nickname!user@host into your IAL and then rejoining a channel you have in common with multiple users will cause those individuals to retain the nickname!user@host in the IAL cache, giving them different colors.

So, it's a tricky business. Maybe Khaled should let us choose how randomized nickname coloring is hashed. By nickname-only, by nickname!user@host, or by Session ID via $ial().id


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
Originally Posted by maroon
I think the color is based on a hash calculation against $address($nick,something), so if the nick identifies after joining the channel, then their address appears to change, and there's a good chance their color would also change.

No nick or address changes, ever. These are people that have been using the same nick and host for years, you can see the conversation for hours then the color randomly switches to a different one.

Joined: Feb 2011
Posts: 461
K
Pan-dimensional mouse
Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 461
What network/channel? Can we idle in it?

Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
The address always changes. It changes from $null to buttercup@ip.123.21.31.41.verizon.net behind the scenes the first time they speak. The color doesn't update immediately, only after they part and rejoin, or you part and rejoin, or whatnot.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
No dude, I'm telling you, there is one dude that has been using the same vps/znc for 10+ years, at one point, while he's talking, the nick goes from for example green to white, after 1-2hrs of being there even, and it stays white until mIRC restarts then it's green again. znc here too so, no parts and no rejoining.

I noticed with other nicks too, they've had the same host for years.

Joined: Feb 2011
Posts: 461
K
Pan-dimensional mouse
Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 461
Could custom schemes be causing the issue?

eahm is using "BlackStuffBlue" that was posted here: https://forums.mirc.com/ubbthreads.php/topics/264467

Code
[colors]
n16=BlackStuffBlue,1,6,4,7,2,2,4,2,2,2,2,15,4,7,2,15,2,2,2,4,2,1,15,1,15,14,15,1,1,15,1



I'm using the stock mIRC classic scheme and I cannot replicate it or maybe I've not been in the channel long enough.
Code
[colors]
n0=mIRC Classic,0,6,4,5,2,3,3,3,3,3,3,1,5,7,6,1,3,2,3,5,1,0,1,0,1,14,6,0,0,1,97


It's happening on EFnet, no chghost/vhost/spoof/whatever.

eahm said the bug happened again while I was inside the channel. The channel ops nick was green then turned white on his screen. I did not see any change on mine.

I have had a /debug window opened for a few days and the persons nick!~ident@host has not changed.

We are both using znc.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
I noticed that the nick colors change if I open the Themes Dialog (Alt + k) and they stick to the new colors until I restart mIRC.

I don't need to change any theme, just by opening the dialog the nick colors just change.

Now, I'm not sure this was the reason it was doing it when I opened this thread but I'm pretty sure that was it, I just noticed this week.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Can you confirm what you're doing in the Alt+K dialog? Are you just looking in there and saving no changes? Or, has the background color changed to something else?

If you're changing the background color's RGB, that can cause colors to change. The number of colors used in the random-nick color palette depends on the RGB of the background, because the number of colors depends on how many other colors there are in the color list who have sufficient contrast against the background. And, if the number of colors in the palette changes, this causes everyone's color to change, for the same reason it changes everyone's color in the earlier MD5 script when you add/remove a color in the script's list-of-colors. More details on how the color palette is possibly chosen is at:

https://forums.mirc.com/ubbthreads.php/topics/266256/re-automatically-colourize-nicknames#Post266256

... where I'm finding that there are multiple combos - at least for background black - where the threshhold of contrast for allowing a color into the nick palette is lower than it should be. There are some shades of blue which are allowed to be for a nick against a black background, and while you can discern them from each other when your eye is right next to the screen, the contrast disappears at a normal eye distance from the monitor.

And I backtrack my earlier guess about the address being used for coloring the nick. It appears that a case-sensitive version of the nick is used for the color, as I see the same color used for the same string at 2 networks where their address details are different, and the nicks are continued to be colored identically regardless whether or not I've used /who to even discover what their address and/or account info is.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
No changes and no theme change, just open the dialog and ...this is the thing I don't remember, I'm not sure if I tried to just open the dialog and hit Cancel or open the dialog browse 1-2-3 themes and hit Cancel but I think I tried the first option too just to see, ALT+k>Cancel and the nick colors change on the new lines of chat.

All these tests are done on a ZNC also but I don't see why it would be any different with a normal session.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
I tested again, ALT+k > Ok = nick colors change. ALT+k > Cancel = nick colors change. Just by opening that panel the nick colors will change. If you restart mIRC all the colors are normal again.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
I can't reproduce this. For the time when this happens again, I'm interested in the output of these command when the colors are normal and again when the colors have changed:

1. Be in enough channels so that your $ial is large enough that there's a good chance that all colors in the random palette will be assigned to at least 1 nick. Probably minimum 500 should be sufficient, based on this estimate:
//echo -a $calc(100*(1-(63/64)^500)) $+ %
2. Save the output of this command when colors are normal:

//var %ch $chan(0) , %a | while (%ch) { var %chan $chan(%ch), %i $nick(%chan,0) | while (%i) { var %a $addtok(%a,$nick(%chan,%i).color,32) | dec %i } | dec %ch } | echo -ag nicks: $ial(*,0) palettesize: $numtok(%a,32) $regsubex(background: $color(background) : $sorttok(%a,32,n),/(\d+)/g,\t $+ : $+ $base($color(\t),10,16,6))

3. Repeat #2 when colors have changed.

4. If you have any other color rules in 'nick colors', and if the random color rule is not the topmost one, this shows which other colors in the above palette list might be in the palette due to a different rule, so it helps to see the result from this:

//var %i 1 , %a | while (%i <= $cnick(0)) { var %a %a $cnick(%i).color $cnick(%i).auto | inc %i } | echo -a %a

The outputs are useless unless there's a pair of outputs from when colors are normal vs when they've changed, so don't send unless you have a pair from when colors are normal/changed.

I'm curious if the palette is staying the same but colors for each nick are changing, or whether the palette is changing to have a different group of colors.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
1st test:
Normal
nicks: 609 palettesize: 4 background: 1:000000 : 3:009300 7:007FFC 15:D2D2D2 52:0000FF

After Alt+k+Cancel
nicks: 609 palettesize: 4 background: 1:000000 : 3:009300 7:007FFC 15:D2D2D2 52:0000FF
Colors HAVE changed.

After Alt+k+Ok
nicks: 609 palettesize: 4 background: 1:000000 : 3:009300 7:007FFC 15:D2D2D2 52:0000FF
Colors HAVE changed.

2nd test:
7 $false 15 $true 2 $false 54 $false 6 $false 52 $false 7 $false 3 $false

My rules:
[cnicks]
n0=$me,7,,,1,1,0,0,0,0
n1=,99,,,1,1,0,1,0,1
n2=,2,.!,,0,0,0,2,0,0
n3=,54,~,,0,0,0,2,0,0
n4=,6,&,,0,0,0,2,0,0
n5=,52,@,,0,0,0,2,0,0
n6=,7,%,,0,0,0,2,0,0
n7=,3,+,,0,0,0,2,0,0

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
According to these results, your random colors consists of only 4 different colors? Either this is true, or my alias is somehow picking up the wrong values. Not only that, but the 4 colors showing up as being in the palette are obviously coming from other rules down below, and none of the colors listed in the palette are coming from the random colors.

Can you confirm which mIRC version you're using?

And can you confirm that you're seeing more colors than just the 4 in your debug message?

Even if you edited your color scheme to have all the colors 0-15 being identical, there should be lots of other colors in the 16-98 range showing up in your colorized nicks.
The only way I see that this should be happening is if you have a script using /cline to change the color of these nicks away from the random colors, but something like that shouldn't be triggered by opening the colors dialog.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
Yeah not sure why it says 4, I see more colors for sure.

I always use the latest version or Beta when available, using and testing on Beta 7.67.5285 right now.

I'm not sure, if that's the debug message I guess it shows 4? I can send my settings if you'd like to test it.

The theme I'm using is this:
n4=BlackStuffBlue,1,6,4,7,2,2,4,2,2,2,2,15,4,7,2,15,2,2,2,4,2,1,15,1,15,14,15,1,1,15,1
n4=16777215,0,12615680,37632,8421631,127,10223772,32764,8454143,8454016,9671424,16776960,16744448,16744703,8355711,13816530

And the only scripts I have loaded are these:
https://forums.mirc.com/ubbthreads....y-buffer-self-message-support#Post269097
and
https://forums.mirc.com/ubbthreads....ow-on-highlights-and-mentions#Post267048

Thanks for checking all this man.

Joined: Dec 2002
Posts: 5,477
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,477
Thanks for looking into this. It looks like the colors are not being updated immediately in some situations. I have made a change that should resolve this in the beta.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
I connected today since that last msg/check and I'm testing it, it seems to be working fine now thanks. Will keep testing.

Joined: May 2018
Posts: 222
eahm Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2018
Posts: 222
They still change, tested on 2 big chans with 200+ users, no znc, they change almost instantly just by opening ctrl+k.

Page 1 of 2 1 2

Link Copied to Clipboard