mIRC Home    About    Download    Register    News    Help

Print Thread
#273423 14/05/25 10:01 AM
Joined: Apr 2005
Posts: 116
X
Vogon poet
OP Offline
Vogon poet
X
Joined: Apr 2005
Posts: 116
; ========== CONFIGURACIÓN ==========
alias ns_nick return xxxxx
alias ns_pass return xxxxxxxx
alias oper_user return xxxx
alias oper_pass return xxxxxx

; Lista de canales a los que te unirás
alias canales {
join #gasy
join #paranachat
join #canal3
join #canal4
}

; ========== PRE-LOGIN ==========
alias prelogin {
echo -a [Pre-Login] Conectado a $server ($network) a las $time
echo -a [Pre-Login] Nick configurado: $ns_nick
}

; ========== EVENTO AL CONECTAR ==========
on *:CONNECT:{
; Solo si estás en gmisiochat
if ($server == irc.gmisiochat.net) {
prelogin

if ($me != $ns_nick) {
nick $ns_nick
}

; Espera 3 segundos antes de identificarte con NickServ
.timerNickServ 1 3 msg NickServ IDENTIFY $ns_pass
}
}

; ========== CUANDO TE IDENTIFICAS CON NICKSERV ==========
on *:NOTICE:*You are now identified*:*:NickServ:{
if ($server == irc.misiochat.net) {
; Ejecutar OPER después de 1 segundo
.timerOper 1 1 OPER $oper_user $oper_pass
; Unirse a canales después de 2 segundos
.timerJoin 1 2 canales
}
}

the login is falling ,any help please ,doesnt work

thanx

XGamerAMD #273436 Yesterday at 11:55 AM
Joined: Aug 2013
Posts: 87
I
Babel fish
Offline
Babel fish
I
Joined: Aug 2013
Posts: 87
Hello,
I'm noticing two things in your on NOTICE event, (and one minor thing in your /prelogin alias):

For the /prelogin alias, ($network) will be treated as plain text, rather than as the identifier $network surrounded by parentheses. In order to get the network name wrapped in parentheses, you will need to use a $+ concatenator (preferably the infix version) between each "(" and ")" parenthesis and the $network identifier:
( $+ $network $+ )

As for the on NOTICE event issues...

The first thing I see there is that you have an extra event parameter:
on *:NOTICE:*You are now identified*:*:NickServ:{

If you remove the part underlined in red, the event should trigger correctly and will no longer attempt to execute "/NickServ:{" as a command whenever anybody sends you a notice containing the text "You are now identified".

The second, which I'm assuming is a typo, is that you're checking if the value of $server is irc.misiochat.net, without a g...
if ($server == irc.misiochat.net) {
...rather than irc.gmisiochat.net, with a g.

Other than those two things, your script should work fine. However, you should also be aware that timers will evaluate identifiers and variables used in their command parameter twice: once when the /timer command itself is encountered and the timer is created, and then again when that timer is actually executed and runs the command you've passed to it.

Although this is unlikely to be an issue for your particular case, you should get into the habit of wrapping any identifiers or variables that you use within a timer's command parameter inside the $unsafe() identifier in order to prevent mIRC from attempting to evaluate them twice. (Imagine, for instance, what might happen if any of your passwords began with a $ or % character.)

So
.timerNickServ 1 3 msg NickServ IDENTIFY $ns_pass
...would become:
.timerNickServ 1 3 msg NickServ IDENTIFY $unsafe( $ns_pass )

And
.timerOper 1 1 OPER $oper_user $oper_pass
...would become:
.timerOper 1 1 OPER $unsafe( $oper_user $oper_pass )

Hope this helps. smile


Link Copied to Clipboard