Category Archives: irc

mIRC script to check and show the pc uptime

Wouldn’t it be nice if just by issuing the command /uptime you could send to the window you have currently open a test like this?

This is what just appeared when I typed /uptime in my mIRC. Obviously my nick has been ripped off for privay reasons

 

It is much more complete than any simple uptime script which tells only your current uptime… I mean, it records you highest time!

Obviously, it requires scripting. Then, as usual, let’s see how the code works, and then let’s comment it.

Open your Aliases Panel, pressing the button, and add this code:

/checkuptime //if ($calc($ticks / 1000) > %UptimeRecord) //set %IlGiorno $asctime(d mmmm) | //if ($calc($ticks / 1000) > %UptimeRecord) //set %UptimeRecord $calc($ticks / 1000)

/uptime {
  //if ($calc($ticks / 1000) > %UptimeRecord) //set %UptimeRecord $calc($ticks / 1000)  
  //say 9,1 It is $day $+ , $time $+ , here in the Italian slumps, and 4Windows $os 9runned *cough*smoothly*cough* for8 $replace($duration($calc($ticks / 1000),2),wk,$chr(32) $+ Week,hr,$chr(32) $+ Hour,min,$chr(32) $+ Minute,day,$chr(32) $+ Day) $+ 9 $+ . Record:7 $replace($duration(%UptimeRecord,2),wk,$chr(32) $+ Week,hr,$chr(32) $+ Hour,min,$chr(32) $+ Minute,day,$chr(32) $+ Day) 9( $+ %IlGiorno $+ )
}

Now, we need to access the Remote Panel, by pressing the button, and add this line:

on 1:START:/timeruptime 0 40 /checkuptime   

or if you already have an on START in there, followed by { and some lines, insert "/timeruptime 0 40 /checkuptime" without quotes just before the } at the end.

You need to add a line also to the Variable Panel, accessible by reaching the Remote or Aliases Panels, and then clicking on the Variables tab. Here add this line:

%UptimeRecord 0

Now press OK and restart mIRC.

This script will check for you every 40 seconds if the current uptime is higher than the stored one, and if it is, updates the record, and stores also the current date. You can change the frequency the script checks the uptime by putting a different value in "/timeruptime 0 40 /checkuptime", for example use 60 instead of 40 if you want to check every minute.

Needless to say, you can, or better you must change the message as well, since as you can see it fits my being italian . Just write what you like, and format the colours and text attributes as you prefer.

This is all, type /uptime and press Enter to see the result.

mIRC script for custom quit messages

Maybe you didn’t know that by doing a simple /quit in mIRC, or pressing the Close Window button in the upper right corner of mIRC Windows, unless you had installed scripts like Polaris, or similar, the others were seeing a simple:

*** Quits: Yournick (your@mask..in.here) (Quit: )

That’s boring! I mean, if you installed Polaris, they’d be seeing this instead:

*** Quits: Yournick (your@mask.in.here) (Quit: (I was using Polaris IRC 2001) Version:(4.0 Platinum) Webpage:(http://www.polaris-central.com) Wasted:(1 Hour 38 Minutes and 36 Seconds Online))

or something alike.

Quite not original.

Now, suppose instead your quit message was something like:

*** Quits: Yournick (your@mask.in.here) (Quit: As soon as I get through with you, you'll have a clear case for divorce and so will my wife. - Groucho Marx)

Much better, at least in my opinion. If you now want to make your quit messages happy and colourful like that one, follow the instructions, and in a few steps you’ll do it .

So, first you need a text file with the lines you want to use in your Quit messages. Here you can find one. Make sure you save the text of the new window in a TXT file in your mIRC folder, or just do [Right Click/Save] on the link.

You can make a file yourself, but make sure you press Enter between the lines, and save that file in the installation folder of mIRC.

You’re ready for the tough work now.

Open the Aliases Panel (just press the button, or do [Tools > Aliases])

I discovered the GIF Uniform palette is the best for windows, thanks to this screenshot ;-)
This is how the quot alias in your Aliases Panel should look like

 

This is what youhave to copy/paste in the Panel (at the end of it):

/quot {
  //if (%Conta == $null) //set %Conta 0
  /inc %Conta 
  if (%Conta > $lines(Quotations.txt)) set %Conta 1
  //quit $read -l [ $+ [ %conta ] ] Quotations.txt
}

supposing you called the file Quotations.txt as I did, and put it in the same folder as mIRC, as I told you.

Now, all you have to do is to use a simple /quot instead of "/quit Message here" when quitting, and every time you’ll send a different Quit message .

Complete mIRC script for event sounds management

And after a long idle period on active scripting, I decided to come back with a useful script, to update a page about a similar issue, which anyway didn’t show anything such advanced.

This script does all the dirty job of managing events that inside mIRC are programmed to be able to generate sounds. It intercepts them, and, if you enabled sounds, it will play the WAVs appropriate for each event (I added to this script the WAVs I use on my own copy of mIRC)

If you wish to download the ZIP, here you go. All the instructions to load it are in the TXT, while in here you can see how you can customize the script itself, and learn how it works. The WAVs have been made mostly using MS Talkit, which you can find in the Download/AudioVideo section, in case you want to make your own WAVs; there’s also a guide to it in the HowTo’s section.

Follows the script listing:

alias sounds {
  //if ($1 == on) { /set %Soundon 1 | echo -a  $+ $color(info text).dd $+ *** Sounds have been activated }
  //if ($1 == off) { /set %soundon 0 | echo -a  $+ $color(info text).dd $+ *** Sounds have been disabled }
}

alias checkquery //if (($query($1).addr != $null) && (%Soundon == 1)) /splay query.wav

CTCP *:DCC:*:{
  if (($2 == send) && (%soundon == 1)) /splay dcc send.wav
}

on *:GETFAIL:*.*:{
  //if (%Soundon == 1) /splay dcc failed.wav
}

on *:FILERCVD:*.*:{
  //if (%Soundon == 1) /splay dcc finished.wav
}


on 1:OPEN:?:*:{
  //if (($pos($strip($1-),Matches for,1) == 1) && (%Soundon == 1)) /splay locator.wav
  else /timer 1 1 checkquery $nick
}

on *:NOTICE:*:*:{
  //if ((($pos($strip($1-),Requested File's on its way! Low CPS Limit:,1) != $null) || ($pos($strip($1-),is on its way.,1) != $null)  || ($pos($strip($1-),Now Sending!,1) != $null)) && (%Soundon == 1)) { /splay File Arriving.wav | goto bother }

  //if ((($pos($strip($1-),is on its way.,1) != $null) || ($pos($strip($1-),Now Sending!,1) != $null)) && (%Soundon == 1)) { /splay File Arriving.wav | goto bother }

  //if ((($pos($strip($1-),You are in que now with number,1) != $null) || (($pos($strip($1-),I have added,1) != $null) && ($pos($strip($1-),in my que,1) != $null)) && (%Soundon == 1))) { /splay Queued.wav | goto bother }

  //if ((($pos($strip($1-),You are already in my que list with,1) != $null) || ($pos($strip($1-),Sorry I am totally maxed out even in que list,1) != $null)) && (%Soundon == 1)) { /splay Queue Finished.wav | goto bother }

  //if ((($pos($strip($1-),Password accepted for,1) != $null) && ($nick == NickServ)) && (%Soundon == 1)) { /splay Identified.wav | goto bother }

  //if ($pos($1-,server flood protection activated,1) != $null) goto bother
  //if ($pos($1-,has opped,1) != $null) goto bother
  //if ($pos($1-,has deopped,1) != $null) goto bother
  //if ($poscs($1-,DCC Send,1) != $null) goto bother

  //if (%Soundon == 1) /splay notice.wav

  :bother
}

on *:TEXT:*:#:{
  //if ($pos($1-,$me,1) != $null) {//if (%Soundon == 1) /splay chimes.wav//if ($window(@calls,1) == $null) /window -n @calls//aline -hp @calls 11 $chan 9 [ $time ] 7 < $nick > 8 $1-
  }
}

on *:CONNECT://if (%Soundon == 1) /splay Connected.wav

on *:DISCONNECT://if (%Soundon == 1) splay Disconnected.wav

And follows the explanation (usage instructions at te bottom of the page).

The first three events (CTCP, on FILERCVD, on GETFAIL) trigger repectively when an incoming DCC send arrives, or a completion or fail of a DCC get occur, and, after checking if the sound output is enabled, play their files.

The on OPEN triggers when a query opens. It checks first if it’s a response of an MP3 sharing script, if not it waits 1 second before playing the Query sound. This is because you may have installed an antispam script (get a look at mine also in the IRC section) which closes instantly the query if it’s detected as spam: in this case you hear the sound only if the query is still open after a second.

The on NOTICE event checks for a lot of things. If NickServ identified you, if your MP3 request has been queued, is arriving, or hasn’t been accepted (works with SpR and SDFind responses only), ignores some frequent useless notices like the oppings, deoppings, flood protections, and after that plays a generic notice sound if no specific event is detected.

The last one, on TEXT, does what I like most: checks wether someone types your nick in a channel, and sounds chimes.wav, logging at the same time the line into a window. 2 things: first, you may want to disable it for specific occurencies (example: you are op, you voice someone, and his lame script -there’s no other way to call it- thanks you automatically; listening to the sounds may be… and is… annoying) so either you disable the sound at all (deleting the line containing "chimes.wav") or add some filters for those occurrencies (you must be a little fluent in mIRC scripting); second, the window logging looks really nice to me, but in the case you find it useless, delete the two lines containing "@calls". You may easily notice how you could completely delete the last statement if you don’t like it for both reasons. Also, it is somewhat"inefficient". That is, checks whatever is written in whichever channel, which means CPU usage. I have a single big on TEXT in my own script which checks a lot of things togheter, but if you have other scripts installed, they may have their own on TEXT routines. In that case the CPU utilization raises, so, if you are a lucky owner of a 1GHz+ CPU, no big deal, only keep in mind that on slower machines, having a mIRC instance which sucks 5% of the CPU is very annoying .

 

Now, how to use it? Simple, after having loaded the script (follow the instructions in the TXT file), do /sounds on and you will be all setted. The script wll begin to play the WAVs when it’s come the moment. Want to watch a movie or play a game? Type /sounds off and mIRC won’t bug you. That’s all.

How to cutomize it? Basically, you can change the name ot location of the WAVs, delete some parts you’re not interested in, but mostly, add other handlers, if you can, and care. Only thing: mIRC will continue to beep if someone writes other lines in a query after the first one, even if sounds are off. I could change that, but I was too lazy in that moment; I don’t even plan to do it in the future… take it as a good excercise on scripting.

mIRC script to format the LOL/BRB/AFK shortcuts into coloured text

I suppose here you do know what lol rofl lmao brb afk and so on mean, so I will just go straight to the point: what if, when you write an anonymous, pale, shortly insignificant "lol" as simplr reply to a witty comment of one of your channelmates, or of your current query pal, mIRC doesn’t actually print out "lol" but something like Laughing Out Loud?

It would be nicer, woulnd’t it? Well, ok ok, don’t just pi$$ me off now, "Why must I send about 30 bytes of data when usually 3 are sufficient? Tenfold increase? Whoa!" Who the heck cares, if you don’t like it visit one of the other marvellous sections of this website, and don’t get fed up with me.

You can use this addon, instead of adding the lines yourself. The instructions are included in the zipped TXT. I suggest you to continue reading anyway, to learn more about how to modify the script.

Here is what will go in your Remote Panel, accessible by pressing the button in mIRC:

on *:INPUT:*:{
  var %C1 = 8
  var %C2 = 3
  //if ($left($1-,1) != /) {
    //if ($1- == lol) { 
      //say  $+ %C1 $+ L $+ %C2 $+ aughing  $+ %C1 $+ O $+ %C2 $+ ut  $+ %C1 $+ L $+ %C2 $+ oud 
      halt
    }

    //if ($1- == brb) { 
      /say  $+ %C1 $+ B $+ %C2 $+ e  $+ %C1 $+ R $+ %C2 $+ ight  $+ %C1 $+ B $+ %C2 $+ ack 
      halt
    }

    //if ($1- == afk) { 
      /say  $+ %C1 $+ A $+ %C2 $+ way  $+ %C1 $+ F $+ %C2 $+ rom  $+ %C1 $+ K $+ %C2 $+ eyboard 
      halt
    }

    //if (($1- == rofl) || ($1- == rotfl)) { 
      /say  $+ %C1 $+ R $+ %C2 $+ olling  $+ %C1 $+ O $+ %C2 $+ n  $+ %C1 $+ T $+ %C2 $+ he  $+ %C1 $+ F $+ %C2 $+ loor  $+ %C1 $+ L $+ %C2 $+ aughing
      halt
    }

    //if ($1- == lmao) { 
      /say  $+ %C1 $+ L $+ %C2 $+ aughing  $+ %C1 $+ M $+ %C2 $+ y  $+ %C1 $+ A $+ %C2 $+ $$  $+ %C1 $+ O $+ %C2 $+ ff
      halt
    }
  }
}

This is a non-exhaustive script which will exchange lines like "lol", "lmao", "rofl", "rotlf", "brb", "afk", and all the others not included, and you’ll want to add, with their coloured aliases, like Laughing Out Loud, Rolling On The Floor Laughing, Away From Keyboard and so on.

Let’s explain now, for you little geeks curious to learn how this piece of art works.

The "on INPUT" triggers when you press the Enter key to send text, and uses $1- to refer to the entered text; in this case we will trigger every line sent to every kind of window (not only channels, but also queries, DCC chats and DCC FileServers). First, the routine checks if the first character is "/", which means it is a command, and it must not be touched (this was intended for future uses, but this check is not necessary, given the script’s structure ). Then it checks if the line is equal to one of the known acronyms, and it provides to send the updated coloured line instead. The %C1 and %C2 variables are used to easily change the colours if you don’t like the default ones. The halt command is to prevent mIRC to send, along with the modified text, also the text you originally typed in, for example "lol".

To add custom acronyms, simply copy the basic subroutine, that is from "//if ($1- ==" to the halt followed by the }. After that, change the string in "($1- == XX)" with your desired acronym, example "($1- == wysiwyg)", and modify the text after /say as well, according to the new formatting: before the first letter of each word put " $+ %C1 $+ " without quotes, and with the spaces, then right after the first letter copy " $+ %C2 $+ " also without quotes and with the spaces, followed by the rest of the word, so the whole thing becomes:

//if ($1- == wysiwyg) {
  /say  $+ %C1 $+ W $+ %C2 $+ hat  $+ %C1 $+ Y $+ %C2 $+ ou  $+ %C1 $+ S $+ %C2 $+ ee  $+ %C1 $+ I $+ %C2 $+ s  $+ %C1 $+ W $+ %C2 $+ hat  $+ %C1 $+ Y $+ %C2 $+ ou  $+ %C1 $+ G $+ %C2 $+ et
  halt
}

I consider this tutorial complete (you may need an IQ of at least 80 to understand this guide).

Scan your IRC channels for an IP, mIRC script

Maybe sometimes you wondered whose IP was the one, for example, you saw on your FTP server, or on the smurf attack list of your firewall. Maybe, that IP belongs to someone who is in one of your channels in IRC; how to find out? Using a made up command which scans the channels you are in for that IP or alias.

The routine looks lihe this:

/findip {
  //set %SearchedIP $1
  set %IPCheck 1
  var %NCanali
  //set %NCanali $chan(0)
  var %CrChan
  set %CrChan 1
  var %TempMask
  :ChanLoop
  //set %TempMask *!*@ $+ $1
  //if ($ialchan(%TempMask,$chan(%CrChan),1).nick != $null) //echo 9 $ialchan(%TempMask,$chan(%CrChan),1).nick in $chan(%CrChan)
  /inc %CrChan
  //if (%CrChan > %NCanali) goto end
  goto ChanLoop
  :end
  set %IPCheck 0
}
       

and you need to put it in the Aliases Panel (accessible by pressing the button in mIRC.

When you want to search for an IP, type, wherever (either in the status window, a channel window, or a chat window): /findip <IP.or.alias.here> … for example:

/findip 142.214.43.4

or

/findip ppp-31xq.nocs.springnets.pk

It is better to search for both, so, if you only got the IP, do a /dns IP, for example:

/dns 142.214.43.4

and in the status window you will find the result of the search. If it is positive, you will get something more like the example above, that is "ppp-31xq.nocs.springnets.pk", otherwise it may not be possible to find an alias for the IP, and in that case you’ll get a "Unable to resolve" message.

If, instead, you only have the alias, do a /dns alias, like:

/dns ppp-31xq.nocs.springnets.pk

and in the status window you will get the corresponding IP.

So, when you have the IP and the alias, use the /findip command on both. If the person is in one of your channels, you’ll see a green text telling you whose that IP/alias is, and in what channel is the nick. If there are no matches, you will get no results. You don’t have to wait long, since usually if in 4 seconds you see no matches, means that the person isn’t in one of your channels.

Find the IP of other people in IRC channels, mIRC script

You can, on IRC, see which IP belongs to a user (whatever you need to know this for, obviously . This is achieved, inside mIRC, with the /dns command. So, for example, if you want to know what IP is using your channelmate Jogi you can do:

/dns Jogi

and you will see, after some time, the IP and the IP name (if there is one) of Jogi in the Status window. So, what’s he big deal you’ll ask, a page just for this command? Not actually, because it may be annoyng to switch to the Status window every time you need to check the IP of a user. So here we’ll make a script which will send a message to our current channel window with the regarding information.

You can use this addon to load the script from within mIRC, instead of writing the lines yourself.

If you want to add the lines yourself, here are the instructions.

Before we begin, let’s recall that you need to press the button in mIRC to access the Remote panel, that is where you edit scripts.

What you need to write there is:

on *:DNS://echo -a Resolved $nick to: Name - $naddress , IP - $iaddress

and the output, after you add this line, press OK, and issue the /dns command on a user, will appear in the active window, and resemble this:

Resolved Joey42 to: Name - co3061808-a.eburwd1.vic.optushome.com.au , IP - 203.164.127.151

In the case the IPname was not available, the field after “Name -” would simply be empty.

You can check with this also the IP corresponding to websites. For example, if you want to know what IP is associated with www.microsoft.com just do:

/dns www.microsoft.com

and the output will be:

Resolved to: Name - www.microsoft.com , IP - 207.46.230.219

and as well see what IP name belongs to an IP you run into:

/dns 65.92.216.192

the output being:

Resolved to: Name - HSE-Montreal-ppp3473182.sympatico.ca , IP - 65.92.216.192

clear enough I’d say.

Now go on IRC and play a bit.

[Updated 15th Sept 2010]
Several visitors have been asking in the comments why, when they do /dns username, they get a strange code instead of the numeric IP address (in the form of 5B26E798.A7F81C6C.2CF41D6B.IP); this is obviously not an IP address, nor a named alias, but just your server that has a “high security” policy, where it normally does not allow users to know each other’s IP addresses and instead outputs that string, which is univocally associated with the user, but cannot be used to determine the real IP. This is a limitation that cannot be worked around per se, still, you could try asking the user for a DCC query session, which is a special private chat where your computers are directly connected to each other, without passing through the server: if the other user accepts your DCC request, then you can see each other’s IP addresses, since your PC’s are directly connected.

Guida di base alla rete IRC di DALnet

Questa quida è stata pensata per tutti quelli che, appena installato mIRC, nel mio canale #Finestre&finestre su DALnet, ma anche altrove, mi (e si) chiedono “Come funziona qui??”

Per quanto io cerchi di essere gentile con tutti, diventa fastidioso rispondere SEMPRE alle stesse domande, e, visto che noi italiani siamo ignoranti, e non conosciamo l’inglese, mi è toccato scrivere questa pagina in italiano, al contrario di tutto il resto del sito

Sembro acido? Nooo è solo una vostra impressione…

Scherzi a parte, basta dire scempiaggini e cominciamo.

1) “Che roba è mIRC??

mIRC è solo un programma, nella fattispecie un “client”, e cioè un programma il cui mestiere è quello di collegarsi ad un server; non confondiamo quindi il programma (mIRC, non l’unico, ma il più famoso) con la rete di chat, che si chiama solo “IRC” (che significa Internet Relay Chat, cioè “Chat basata su Internet”, per tradurre in maniera piuttosto libera). La rete IRC che io uso è DALnet, ed è anche la rete “spiegata” in questa pagina, così come penso sia la rete alla quale voi siete collegati in questo momento (anche perché mIRC vi si collega automaticamente). Ogni rete IRC (quindi anche DALnet) è composta da un insieme di server, cioè computer, collegati tra loro, e ai quali sono a loro volta collegate tutte le persone che vi si trovano per chattare; per cui è possibile che io sia collegato al server “x” di DALnet, e voi siate collegati al server “y” di DALnet, e nonostante questo possiamo parlarci senza problemi, perché ogni server di DALnet manda a tutti gli altri le righe di testo che gli passano attraverso.

2) “Vabbé, ma ora che faccio??

Una volta collegati ad IRC (ed in particolare a DALnet) dovrete andare in qualche stanza, più comunemente chiamata “canale”, se volete parlare con qualcuno. Su DALnet ci sono moltissimi canali, circa 18000, ed ognuno può crearne di nuovi, per cui aumentano in continuazione. Voi potete sia vedere quali sono i canali che l’autore di mIRC (Khaled Mardam-Bey) ha deciso di includere nella lista del programma, e che si apre appena voi vi collegate, ma che potete richiamare anche premendo il pulsante “List Channels” (), oppure potete decidere (meglio) di scaricare la lista di TUTTI i canali, premendo il pulsante “List Channels”

Da questa finestra potete entrare in un canale facendo doppio click sul #nomecanale oppure selezionando un canale dalla lista e premendo il tasto “Join”. Se non volete che questa finestra compaia ogni volta che vi collegate, disabilitate la casella sul fondo, “Pop up folder on connect”
Questa è la finestra List Channels, basta premere “Get List!” (qui il pulsante è grigio perché non ero collegato a DALnet, voi lo vedrete accessibile) per scaricare la lista completa dei canali
Questa è la finestra che vedrete mentre prendete la lista. Aspettate che abbia smesso di scaricare la lista (ve ne accorgerete perché i numeri nel titolo della finestra smetteranno di aumentare)
Quando avrete finito di scaricare la lista, potrete premere di nuovo il pulsante “List Channels”, e scrivere una parola chiave nella casella “Match Text”. Io ho scritto “italia”, ma voi potete provare con “amici”, “calcio”, il nome della vostra città, eccetera. Premete “Apply” per vedere i canali che contengono “italia” nel nome o nella descrizione.
Questi sono i primi canali che compaiono cercando “italia”, basta fare doppio click sul nome del #canale per entrare. Il canale #italia è una bolgia infernale, non aspettatevi di potervi intavolare una discussione. Comunque, provateci Come vedete ci sono anche canali non italiani, starà a voi capire quando il risultato è poco pertinente.

Se vi collegate di nuovo a DALnet, e volete rientrare nei canali che già conoscete, basterà scrivere, in qualunque finestra (Status, o anche le altre) /join #nomecanale, ad esempio /join #finestre, oppure, se volete entrare nel canale automaticamente ogni volta che vi collegate, potete aggiungere questo comando alla lista dei comandi che mIRC esegue quando si connette: premete il tasto “Options” e andate nel pannello “Perform”

Per abilitare l’esecuzione automatica dei comandi dovete attivare la casella “On connect, perform these commands” e scrivere nella finestre sottostante il comando che abbiamo visto prima, per esempio “/join #finestre“. Potete inserire più comandi di questo tipo, ad esempio si può aggiungere una riga per ogni canale che vi interessa.

3) Mi sono dimenticato cosa volevo scrivere

4) Ah! Mi sono ricordato!

5) “Perché dopo un po’ il mio nick diventa Guest6274638??

Questo succede perché, se è la prima volta che usate DALnet, e scegliete un nick “troppo facile”, è probabile che qualcuno l’abbia preso prima di voi (su DALnet non possono esserci due nick uguali, come in ICQ o MSN). A quel punto, dopo un pò “NickServ”, che è il server in DALnet che controlla la validità dei nick, ve lo toglierà, e vi darà un nick come “Guest6274648”. Rassegnatevi, dovrete sceglierne un altro, oppure modificare un po’ quello. Ad esempio, se “Antonio” è già preso, provate “Antonio^”, e se è preso anche quello, provate “^Antonio^” eccetera eccetera. Attenzione però, non tutti i caratteri sono accettabili: per esempio i segni di punteggiatura o l’apostrofo; provate con trattini, parentesi, e altri caratteri. Quando avrete scelto il nuovo nick, provate a usare il comando /nick nuovonick, ad esempio “/nick ^Antonio^“, e, se non c’è nessuno che lo sta già usando in quel momento, lo prenderete voi. Potete usare il comando /nick quante volte volete, ma non ripetetelo velocemente, altrimenti verrete messi in attesa come “punizione”

6) “Come mi accorgo se il nick che ho scelto non appartiene a nessuno??

Se scegliete un nick, ed entrate in DALnet per la prima volta, ci sono diverse possibilità: 1) il nick che avete scelto non è utilizzato, né appartenente aa un’altra persona che lo ha registrato, ed allora potrete tenerlo per tutto il tempo in cui siete connessi; 2) c’è già un’altra persona collegata che sta usando quel nick, quindi voi non potrete usarlo; 3) non c’è nessuna persona che sta già usando quel nick, ma qualcuno che non è connesso lo ha già registrato, e allora “NickServ” dopo un po’ ve lo cambierà ad esempio in “Guest482853”. Quando avrete cambiato nick (col comando /nick nuovonick), e NickServ non avrà nulla da ridire, significa che quel nick è “originale”, e potrete usarlo senza problemi.

7) OK, ma come faccio a registrare il mio nick per non farlo usare a nessun’altro??

Per registrare un nick dovrete fare una richiesta a NickServ, con un comando particolare con cui dovrete fornirgli un po’ di dati. Quando state usando il nick che volete registrare (e se siete sicuri che non è registrato a nessun’altro) usate questo comando: /nickserv register vostrapassword vostraemail (ad esempio, se volete usare come password il nome del vostro cane “ermenegildo”, e il vostro indirizzo di posta elettronica è “io.sono@sfigato.it”, dovrete scrivere: /nickserv register ermenegildo io.sono@sfigato.it).
Ed ora un pò di raccomandazioni: l’indirizzo di posta elettronica deve essere vero! NickServ vi manderà un messaggio con un indirizzo web che dovrete visitare per attivare definitivamente la registrazione. Se non lo fate, dopo 24 ore il nick perderà la registrazione. Dopo averlo definitivamente registrato, dovrete usarlo almeno una volta al mese, altrimenti la registrazione verrà comunque persa. Altra precauzione: quando scrivete il comando per la registrazione, anche se potete farlo in qualunque finestra, vi conviene usare la finestra Status, perché se vi sbagliate, e ad esempio dimenticate di scrivere “/” all’inizio, se siete in un canale tutte le altre persone vedranno la vostra password!

8) Passare al punto 10

9) “Ho già registrato il nick, ma divento sempre Guest36524!!! Perché????

NickServ purtroppo non è telepatico, per cui ogni volta che vi collegate a DALnet con un nick che avete registrato, se non volete che NickServ ve lo tolga, dovrete dimostrargli che è vostro, dicendogli la password con cui l’avete registrato. Per fare questo dovete usare il comando: /nickserv identify vostronick vostrapassword (ad esempio, se il vostro nick è “^gigilatrottola^” e la vostra password è il nome del vostro cane, “ermenegildo”, dovrete scrivere: /nickserv identify ^gigilatrottola^ ermenegildo). Anche in questo caso, se lo scrivete a mano, vi conviene usare la finestra Status. Altrimenti, potete aggiungere anche questo alla lista “Perform”… ve la ricordate vero?????

Questa è come apparirà la finestra “Perform” dopo aver aggiunto il secondo comando per identificarsi con NickServ appena vi collegate a DALnet. Non dimenticate che, quando avrete imparato un po’ di comandi, potrete aggiungere qui tutti quelli che volete vengano eseguiti appena vi collegate!!!

A questo punto potete senz’altro passare al punto 11

10) Questo punto è vuoto. Voltarsi, fare una capriola mortale, e lanciare di nuovo i dadi. Dopo di ciò, tornare indietro al punto 9

11) Ora mi sono veramente stufato. Se volete che aggiunga qualcosa, scrivetemelo in e-mail, oppure venite a chiederlo nel mio canale #finestre (basta che non arriviate la sera tardi, perché mi piace dormire 8 ore al giorno)

Autoaway script for mIRC

The away flag is a very useful one, lets you be “justified” if you don’t answer someone’s query, or even lurk in incognito, so the pesters you don’t want to chat with, think you are not at the computer. In the first case, it often happens that you simply leave the PC connected, being AFK, but forget to activate the away. A simple script can check for how long you’ve been “idle” with mIRC (the idle time in mIRC represents the time from the last stroke on the Enter key, no matter if it’s been used to send a line to a channel or a chat window, or just to identify to NickServ, or something else).

You need to set both an alias and a script (this will work fine enough if you just installed a clean mIRC, or anyway if you’re not using other scripts).

You can use this addon to load the script without adding the lines yourself. All the instructions are in the TXT file, follow them. I suggest you to continue reading anyway, so you can have more details about the script.

Here’s what you need to add in the Aliases Panel (accessible pressing the button):

/CheckAway {
  //if (($idle > 300) && ($away == $false)) //away 8,2 I am away after 5 idle minutes
  //if (($idle < 300) && ($away == $true)) /away
}

Customize this alias by changing the idle time with the one you prefer (I setted it to turn on the away flag after 5 minutes – 300 seconds; just put your preferred idle time, in seconds, instead of the two “300” you find there), and putting a message you like instead of “I am away after 5 idle minutes” (the “8,2” is used to set the colour of the message. If you don’t know how to use colour codes in mIRC, leave it as it is, or remove it if you don’t like the colours I use .

Here’s instead what you need to add in the Remote Panel (accessible pressing the button):

on *:CONNECT:/timerChkAway 0 10 /CheckAway

If you followed the instructions in the other pages of this section, and already added an on CONNECT line, add the “/timerChkAway 0 10 /CheckAway” line as well to the routine. If you instead want to add the other scripts in these pages, then do the same, by using something like:

on *: CONNECT:{
  line1
  line2
  line3
  ...
  ...
}

and putting the proper commands where you find “line1” “line2” and so on.

Now, using this script togheter with the AutoAnswerer script you can find in this section, you will have a complete set of away scripts.

DALnet Auto Identify and Auto Op mIRC script

You may think all it’s needed to shut up NickServ when you login on DALnet is putting a /nickserv identify password or /msg nickserv@services.dal.net identify command in the [File > Options > Perform] panel of mIRC… well… actually, it would. As in a perfect world there would be no wars nor poverty nor starvation, but NickServ isn’t perfect (ChanServ isn’t as well, that’s why we are going to speak about him as well, later), so you need to prevent all those situations which may determine NickServ to forget you identified some time bfore, and kicking you to a shameful status of Guest*****.

We’ll explain here how to get rid of these unpleasant situations with a script, not too long, not too short, not perfetc as well, but there is room for betterings.

You can use this addon to load the script instead of writing the lines yourself. Faster, easier, no conflicts with other scripts. Instructions are included in the TXT file, follow them. If you want to edit the script yourself, or just know how it works, continue reading (suggested).

(Note) The script has been lately updated to be more reliable in avoiding the flood of services. In some cases it c0uld, especially if you registered 4 nicks or more, lead to many repeated identification requests, up to making the services upset. Once I even got banned by an IRCop, so I finally decided to put my hands on the old code.
The comments to these upgrades aren’t in the paragraphs below, but what they do is adding another procedure to request both the identification and the ops instead of doing it directly. This procedure checks on a flag (one variable allocated for each nick and each channel), and if the flag is unsetted it requests either the identification or the ops, then sets the flag, which avoid successive repeated requests to be accepted. The flag is unsetted after 60 seconds, making it possible to request identification or ops again.

The messages you see NickServ sends you when you join, telling you "This nick is owned by someone else…" "If this is your nick…" "Password accepted for…" are called "notices". You’ll set a listener for notices coming from NickServ and containing specified patterns of text, so to act depending on what NickServ wants from you.

Enuf talking, let’s come to action:

on *:CONNECT:{
  /dcc packetsize = 4096
  /pdcc 2147483647
  /fsend on
  /joinall
}


on 1:START:/timerIdent 0 40 /ident

on *:NOTICE:*:*:{
  if (($pos($strip($1-),Password accepted for,1) != $null) && ($nick == NickServ)) {
    //if $pos($strip($1-),YourMainNick,1) != $null) {
      /timer 1 20 /autoop 
      /nick YourMainNick
    }
    goto bother
  }
  if (($pos($strip($1-),This nick is owned by someone else. Please choose another.,1) != $null) && ($nick == NickServ)) /id
  if (($pos($strip($1-),Your nick has been changed to Guest,1) != $null) && ($nick == NickServ)) {
    /id
    /nick YourNick^_^
  }
  if ((($pos($strip($1-),You do not have access to op people on #YourChannel.,1) != $null) || ($pos($strip($1-),#YourChannel is operated by ChanServ,1) != $null)) && ($nick == ChanServ) && ($me !isop #YourChannel)) /id
  :bother
}

where /joinall /autoop /ident
and /id are aliases defined as:

/joinall {
  /join #channelone
  /join #channeltwo
  /join #channelthree
  ...
}

/autoop {
  /timer 1 0 //chanserv op #ChannelOne $me
  /timer 1 5 //chanserv op #ChannelTwo $me
  /timer 1 10 //chanserv op #ChannelThree $me
  ...
}


/ident {
  //if (($me == YourNick^_^) || ($me == YourAltNick) || (Guest isin $me)) /nick YourNick

}

/id {
  //if ($me != YourNick) /timer 1 0 /nickserv ghost YourNick yourpassword
  /timer 1 5 /nickserv identify YourNick password
  /timer 1 10 /nickserv identify NickTwo password
  ...
}

Those lines must be added to the Remote and Aliases panels in mIRC (the on CONNECT, on START and on NOTICE must go in the Remote Panel, the /joinall /autoop /ident and /id must go in the Aliases Panel), accessible pressing the buttons and . Check those panels for other occurences of the routines. If you find there’s already an on CONNECT and/or on START and/or on NOTICE in the Remote Panel, you may have installed a script like Polaris, i², Siralop, Invision, or another script (in this case, if you don’t know what that part of the script does, better not to mess, simply stop reading this page and wait to be more acquanted with scripting), so you need to modify/extend the routines adding the lines; if you instead did those scripts yourself, you should know how to modify them properly. In the same way, if there are already aliases named joinall autoop and id in the Aliases Panel, follow the same directives (don’t touch anything if you don’t know what it is, or modify the aliases as you need).

 

Obviously you need to change YourNick, YourChannel, yourpassword with the real ones. "YourMainNick", if you own more than one nick, is the nick, you are operator with, in your channels; if you own only one nick, simply put that one. "YourNick^_^" is your actual nick with a "^_^" after it (supposing it is not registered), so to make you have a real nick while you wait for nickserv to confirm your identification; "YourAltNick" is the nick you wrote as "Alternative" in the mIRC [File > Options > Connect] panel.

The "…" must not be included, but you can add or remove other similar lines in case you are op in more channels or own more nicks. The delayed commands (/timer 1 …) are needed to avoid to flood services which may ignore you if you issue too many requests all togheter (just keep adding the right amount of seconds for each line you add).

In the main script, where you see the lines "You do not have access to op people on #YourChannel." and "#YourChannel is operated by ChanServ" you should write the name of the channel, you are op in, that you join last.

The additional commands on the on CONNECT script should accelerate DCC sends, I suggest you to leave them there.

 

You didn’t get the hidden meaning? Ok, let’s explain what this script does. It waits for NickServ to ask you to identify, then sends the identify command(s); when you are identified, it asks chanserv to op you in the channels you are operator in, and repeats asking this until chanserv does op you. Whenever nickserv or chanserv forget you are identified and operator, it re-issues the identify and op commands, and in the dreaded case nickserv is badly lagged, and you get renamed to Guest, it gives you another temporary nick, until the identification is done. In the case you get disconnected by peer, and you reconnect while you ghost is still "online", it waits for nickserv to confirm the identification, and if your current nick is different from your usual one (that is, the ghost is already using it, and you are named after your alternative nick), it issues a kill ghost command.

An efficient antispam and away autoreply script for mIRC

I add or update my scripts as it become needed. So, an antispam script is one among the first I did, since, no matter what channels you lurk in, there’s always a lamer sending ads of websites, channels, whatever.

An antispam script does nothing else that recognising some specified patterns in a query window, and ignoring it if it has the appearance of spam.

Briefly, you can download this addon to load from mIRC instead of adding the lines yourself. Instructions of use, along with possible changes you may need to make, are included in the TXT file itself. If you want to edit the lines yourself, or just want to know how the script works, continue reading.

The event in mIRC which triggers the opening of a query window is on OPEN, and the following lines will show how to use it:

on 1:OPEN:?:*:{....

The "?" specifies that the event will trigger only query windows, and the "*" specifies no particular text matches for now (we are going to include all the matches in the body of the script).

My script does 4 things: check if the messaging nick is an operator in one of the channels I am in, and in this case does not filter the message, otherwise it will be processed. If the user who sent you the message is in none of your channels, the message is ignored by default. If it is all ok, another procedure checks if I am away, and in that case tells the nick that I may not be at the computer, or, if it’s late, that I also may be sleeping. If the message is recognised as spam, the window is closed, and a minimized log window is open (if it doesn’t already exist), where you can check the supposed spam messages you received, so to correct te script if some of them weren’t spam.

Here’s the full text script (note: this script works under mIRC v5.9, don’t know about older versions):

on 1:OPEN:?:*:{
  var %Ghost
  set %Ghost 1
  var %Cnt
  set %Cnt 1
   :Loop
  //if ($nick isop $chan(%Cnt)) goto allok
  //if ($ialchan($nick,$chan(%Cnt),1) != $null) set %Ghost 0
  inc %Cnt
  //if (%Cnt < = $chan(0)) goto Loop
  //if (%Ghost == 1) goto absent
  if ($strip($1-) == hello,) goto lamer
  if ($strip($1-) == hello) goto lamer
  if ($strip($1-) === hi) goto lamer
  if ($strip($1-) == hallo) goto lamer
  if ($strip($1-) == holla) goto lamer
  if ($pos($strip($1-),#,1) != $null) goto lamer
  if ($pos($strip($1-),j o i n,1) != $null) goto lamer
  if ($pos($strip($1-),how are you,1) != $null) goto lamer
  if ($pos($strip($1-),how are u,1) != $null) goto lamer
  if ($pos($strip($1-),www.,1) != $null) goto lamer
  if ($pos($strip($1-),slm,1) != $null) goto lamer
  if ($pos($strip($1-),asl,1) != $null) goto lamer
  if ($pos($strip($1-),gamez,1) != $null) goto lamer
  if ($pos($strip($1-),leech,1) != $null) goto lamer
  if ($pos($strip($1-),join,1) != $null) goto lamer
  if ($pos($strip($1-),plz come,1) != $null) goto lamer
  if ($pos($strip($1-),pls come,1) != $null) goto lamer
  if ($pos($strip($1-),/server,1) != $null) goto lamer
  if ($pos($strip($1-),www.cheatos.com,1) != $null) goto lamer
  if ($pos($strip($1-),serv,1) != $null) goto lamer
  if ($pos($strip($1-),click here,1) != $null) goto lamer
  if ($pos($strip($1-),xguest,1) != $null) goto lamer
  if ($pos($strip($1-),/server,1) != $null) goto lamer
  if ($pos($strip($1-),check out my pics,1) != $null) goto lamer
  if ($pos($strip($1-),check my pics,1) != $null) goto lamer
  if ($pos($strip($1-),http://,1) != $null) goto lamer
  if ($pos($strip($1-),sex,1) != $null) goto lamer
  if ($pos($strip($1-),porn,1) != $null) goto lamer
  if ($pos($strip($1-),we need,1) != $null) goto lamer
  if ($pos($strip($1-),chat,1) != $null) goto lamer
  if ($pos($strip($1-),Matches for,1) == 1) goto Results
  goto allok
  :absent
  /query $nick Not in any of my channels. Message ignored.
  /close -m $nick
  goto end
  :lamer
  /query $nick This message's been detected as an invite/whatever else, so this window is being closed. My script can't be 100% accurate, so sorry if it's not your case.
  /close -m $nick
  //if ($window(@lamerz,1) == $null) /window -n @lamerz
  //aline -hp @lamerz 9 [ $time ] 7 < $nick > 8 $1-
  goto end
  :allok
  //if ($away == $true) {
    //if ($asctime(H) < 9) //query $nick [Automated Response] It is $asctime(H:nn) $+ $asctime(tt) here, and I am away ( $+ $duration($idle,2) idle), so I may be sleeping.
    else //query $nick [Automated Response] I am away ( $+ $duration($idle,2) idle). I could answer you if I'm here and the speakers are on ;-)
  }
  :end
}

HTML doesn't allow easy indenting, but when you'll copy/paste this in your mIRC/Remote panel, accessible by pressing the button , and then press the [OK] button, it will be automatically indented.

Important: check if your Remote Panel already contains an [on *:OPEN:?:...] event. In this case, either you did that script, so you don't need me to tell you how to modify it, or you had another script installed, like Polaris, Siralop, Invision, whatever and it probably includes an antispam routine itself, so you don't need this guide.

How you can customize this script:

  • Add new keywords: if you notice that some spam doesn't get filtered, you can add the peculiar words in it to the list, just by copying a line and substituting the keywords. For example, if they open a query window which starts like this: "Hello <yournick>," (while nobody usually opens such query windows just to chat), simply add a line like "if ($pos($1-,Hello <yournick>,,1) != $null) goto lamer" among the others.
  • Specify detailed patterns: you can also check case sensitive keywords. For example, if your nick is JoE^ and you want the above keywords to be case sentitive, put the same line, but substitute "$pos" with "$poscs" so it will become "if ($poscs($1-,Hello JoE^,,1) != $null) goto lamer". Also you can determine if the message must start with those keywords, and not just contain them. In that case, substitute "!= $null" with "= 1" so the line will become "if ($poscs($1-,Hello JoE^,,1) = 1) goto lamer".
  • Specify whole messages: you can as well filter exact sentences, instead of checking if a sentence contains some keywords. In that case simply add a line like "if ($1- == Hello,) goto lamer" which for example will trigger on evey query window equal to "Hello,". This is not case sensitive; if you want a case sensitive check substitute "==" with "===", like "if ($1- === Hello,) goto lamer".
  • Modify the sleep time: my supposed sleep time goes from 0:00 to 8:59; means that a query window received between these times will be answered with the "I am sleeping" message. You can correct this by modifying the Hour time, from 9 to 10 for example, if you want the interval to end at 9:59, or to 8, if you want instead 7:59. If you want to modify the first time, 0:00, you should also add some text to the script. It can be easily done, anyway I don't have right now the time to add a tutorial on this, plus I don't think it's of vital importance wheter the script guesses exactly wheter you are sleeping or not.