mIRC Home    About    Download    Register    News    Help

Print Thread
#246334 04/06/14 08:51 AM
Joined: Apr 2014
Posts: 5
T
tlchost Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Apr 2014
Posts: 5
I found a script that sends a message to a nick when the command /NICK is entered:

on *:NICK: /msg $newnick Hey $newnick $+ , weren't you just $nick $+ ? You can't fool us! smile

How can I have the message show in the channel, rather than to the nick ?

I would also like to have a script write to a file the date and time a nick changed nicks...something like

06/03/2014 0400 tlchost changed nick to helper

Thanks

Joined: Mar 2014
Posts: 52
P
Babel fish
Offline
Babel fish
P
Joined: Mar 2014
Posts: 52
msg $chan will send to the channel
and msg $nick will message the user

Code:
write log.txt $time(yyyy-mmm-dd) $time(hhnn) $nick changed nick to $newnick


this should work

Joined: Apr 2014
Posts: 5
T
tlchost Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Apr 2014
Posts: 5
Originally Posted By: patrickplays

Code:
write log.txt $time(yyyy-mmm-dd) $time(hhnn) $nick changed nick to $newnick



Did not write the file

Joined: Dec 2013
Posts: 779
N
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Make sure you have your brackets. From the way you posted the first script, I imagine that you never cared to look into how the system works and thus ignored the brackets.

Code:
on *:NICK: { 
msg $chan $nick just became $newnick trying to fool us!
write log.txt $time(yyyy-mm-dd) $time(hhnn) $nick changed nick to $newnick
}


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Joined: Apr 2014
Posts: 5
T
tlchost Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Apr 2014
Posts: 5
Originally Posted By: Nillen
Make sure you have your brackets. From the way you posted the first script, I imagine that you never cared to look into how the system works and thus ignored the brackets.


BTW, I imagine you never cared to test the code you gave me...while it does write to log.txt, it apparently does not write the message to the channel.

Thanks for the code to write the log file.

Quote:

Code:
on *:NICK: { 
msg $chan $nick just became $newnick trying to fool us!
write log.txt $time(yyyy-mm-dd) $time(hhnn) $nick changed nick to $newnick
}

Joined: Jan 2004
Posts: 1,361
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Jan 2004
Posts: 1,361
$chan is not valid in a nick event, you can loop through $comchan to msg all chans you have in common. Messaging the channel seems like spam though, why would you need to do so?

Joined: Apr 2014
Posts: 5
T
tlchost Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Apr 2014
Posts: 5
Originally Posted By: Loki12583
$chan is not valid in a nick event, you can loop through $comchan to msg all chans you have in common. Messaging the channel seems like spam though, why would you need to do so?


not being valid explains why it doesn't work...thanks.

One man's spam is another's information.

Joined: Jan 2004
Posts: 1,361
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Jan 2004
Posts: 1,361
Information that every client can already display for itself?

Joined: Apr 2014
Posts: 5
T
tlchost Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Apr 2014
Posts: 5
Originally Posted By: Loki12583
Information that every client can already display for itself?


Some don't know how..thanks for your interest and help.


Link Copied to Clipboard