mIRC Home    About    Download    Register    News    Help

Print Thread
On Nick event problem #135954 20/11/05 05:24 AM
Joined: Oct 2005
Posts: 75
C
Confuzzled Offline OP
Babel fish
OP Offline
Babel fish
C
Joined: Oct 2005
Posts: 75
i made this,

on *:nick:{
if ($newnick == MyNick) { unload -rs $mircdirRemotes\IsLndBot1.mrc | unload -rs $mircdirRemotes\IsLndBot2.mrc | unload -rs $mircdirRemotes\IsLndBot3.mrc | unload -rs $mircdirRemotes\IsLndBot4.mrc | unload -rs $mircdirRemotes\IsLndBot5.mrc }
if ($newnick == MyBotNick) { load -rs $mircdirRemotes\IsLndBot1.mrc | load -rs $mircdirRemotes\IsLndBot2.mrc | load -rs $mircdirremotes\IsLndBot3.mrc | load -rs $mircdirremotes\IsLndBot4.mrc | load -rs $mircdirremotes\IsLndBot5.mrc }
{ else notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11. }
}

it works fine with me but when i try to change my nick to different nick other than those other two it gives me the else line too notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11.

how can i make that line triggered only for others but not for me and those other two nick i put in there?

Re: On Nick event problem #135955 20/11/05 06:09 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
 on *:nick:{
if ($newnick == MyNick) {
 unload -rs $mircdirRemotes\IsLndBot1.mrc
 unload -rs $mircdirRemotes\IsLndBot2.mrc
 unload -rs $mircdirRemotes\IsLndBot3.mrc
 unload -rs $mircdirRemotes\IsLndBot4.mrc
 unload -rs $mircdirRemotes\IsLndBot5.mrc
 }
elseif ($newnick == MyBotNick) {
 load -rs $mircdirRemotes\IsLndBot1.mrc
 load -rs $mircdirRemotes\IsLndBot2.mrc
 load -rs $mircdirremotes\IsLndBot3.mrc
 load -rs $mircdirremotes\IsLndBot4.mrc
 load -rs $mircdirremotes\IsLndBot5.mrc
 }
elseif ($newnick != $me) {
 notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11. 
}
}
 


I removed the | from your code, simply because I find codes easier to read without them, and in the format that I have above, they aren't needed.


Last edited by RusselB; 20/11/05 06:22 AM.
Re: On Nick event problem #135956 20/11/05 06:19 AM
Joined: Oct 2005
Posts: 75
C
Confuzzled Offline OP
Babel fish
OP Offline
Babel fish
C
Joined: Oct 2005
Posts: 75
ok it looks neater now thank you but still works the same,

i want to have this line,

notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11.

work for others only, cause if i change to different nick from those two i have it does that line to me too. i want to know if it can only work for others except me

Re: On Nick event problem #135957 20/11/05 06:22 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Try the edited version

Re: On Nick event problem #135958 20/11/05 06:29 AM
Joined: Oct 2005
Posts: 75
C
Confuzzled Offline OP
Babel fish
OP Offline
Babel fish
C
Joined: Oct 2005
Posts: 75
i changed else alone to one you just edited

elseif ($newnick != $me) {
notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11.
}
}

but still work the same, the msg keep on coming to me too

Re: On Nick event problem #135959 20/11/05 06:37 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
 on me:*:nick:{
if ($newnick == MyNick) {
 unload -rs $mircdirRemotes\IsLndBot1.mrc
 unload -rs $mircdirRemotes\IsLndBot2.mrc
 unload -rs $mircdirRemotes\IsLndBot3.mrc
 unload -rs $mircdirRemotes\IsLndBot4.mrc
 unload -rs $mircdirRemotes\IsLndBot5.mrc
 }
elseif ($newnick == MyBotNick) {
 load -rs $mircdirRemotes\IsLndBot1.mrc
 load -rs $mircdirRemotes\IsLndBot2.mrc
 load -rs $mircdirremotes\IsLndBot3.mrc
 load -rs $mircdirremotes\IsLndBot4.mrc
 load -rs $mircdirremotes\IsLndBot5.mrc
 }
}
on !*:nick:{
 notice $newnick 4I see you change from 11.:11.:12 $nick :11.:11. 4to 11.:11.:12 $newnick :11.:11. 
}
 


Sorry, wasn't thinking straight when I did it the first time. Try that instead

Re: On Nick event problem #135960 20/11/05 06:42 AM
Joined: Oct 2005
Posts: 75
C
Confuzzled Offline OP
Babel fish
OP Offline
Babel fish
C
Joined: Oct 2005
Posts: 75
oh ok,
so all i need is another newline with that ! then sorry for the trouble, my mistake

huge thanks by the way

Re: On Nick event problem #135961 20/11/05 06:46 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Please note that you now have two ON NICK events in the same script. The first one, will ONLY activate for you, the second one will activate for anyone EXCEPT you.

Re: On Nick event problem #135962 20/11/05 06:50 AM
Joined: Oct 2005
Posts: 75
C
Confuzzled Offline OP
Babel fish
OP Offline
Babel fish
C
Joined: Oct 2005
Posts: 75
yes thank you again it works now thank you much

Re: On Nick event problem #135963 20/11/05 07:27 AM
Joined: Oct 2005
Posts: 54
B
benjy355 Offline
Babel fish
Offline
Babel fish
B
Joined: Oct 2005
Posts: 54
...mmkay stupid question
what are all the squares for?


Chat NSN
My Server: sleepystickman.ircxpro.com
Re: On Nick event problem #135964 20/11/05 07:33 AM
Joined: Dec 2002
Posts: 3,547
S
SladeKraven Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
What squares are we looking at?

-Andy

Re: On Nick event problem #135965 20/11/05 07:37 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
That's what you get when using CTRL+K to start/end a coloring process around text. they also show up for CTRL+B (Bold) & Ctrl+U (Underline)