Periodic Nick Reset for mIRC

By Tritonio on Jan 11, 2015

My connection drops very often so I end up using the alternative nickname all the time. Here's a tiny script to reset nicknames to the primary one periodically.

Some channels will make it impossible for you to change nick though with a message like this:

[04:55] Tritonio ##hamradio Cannot change nickname while banned on channel

(although I was not banned) or something like this:

[04:55] #news Cannot change nickname while banned or moderated on channel

No idea what these two mean to be honest. :-)

alias resetNick {
  var %i = 1
  while ($scon(%i)) {
    scid $scon(%i)
    nick $mnick
    inc %i
  }
}

on *:START:{
  timer 0 300 /resetnick
}   

Comments

Sign in to comment.
raccoon   -  Jan 12, 2015

Without changing the dynamics or method of your script, here is a perfectly simplified version. I also want to note that you could have used scon %i instead of scid $scon(%i) to the same effect. But here's the short version of the same method.

on *:START: {
  .timerResetNick -oi 0 300 /scon -at1 /nick $!!mnick
}

What has changed: We use the -oi flags to keep the timer running even after you disconnect -o or close the server window that created it -i. We name the timer ResetNick so we know what it is in your /timers list. Using /scon -at1 allows you to issue the same command to all -a server instances that are currently connected -t1. The $!! in $!!mnick makes sure that it evaluates for that specific server instance ... one ! gets used up by the /timer command, another gets used up by the /scon -a command.

The reason you are getting Cannot change nickname while banned or moderated on channel messages is because you are not logged in with NickServ while in channels that require registration to speak, or you are otherwise banned or quieted but haven't been kicked out.

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.