mIRC Home    About    Download    Register    News    Help

Print Thread
#175050 16/04/07 09:11 PM
Joined: Feb 2007
Posts: 27
S
s0urce Offline OP
Ameglian cow
OP Offline
Ameglian cow
S
Joined: Feb 2007
Posts: 27
if ($1 == .deny) {
$read(c:\users\matthew\rp.txt,s,$2)
write -dl$readn c:\users\matthew\rp.txt
}

Why doesn't this work?
Been working on it all day..

s0urce #175051 16/04/07 09:14 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
You need a space before $readn. You should also use the /noop command to prevent $read from doing anything other than getting the line number.

Code:
if ($1 == .deny) {
  noop $read(c:\users\matthew\rp.txt,s,$2)
  write -dl $readn c:\users\matthew\rp.txt
}


Invision Support
#Invision on irc.irchighway.net
Riamus2 #175052 16/04/07 09:21 PM
Joined: Feb 2007
Posts: 27
S
s0urce Offline OP
Ameglian cow
OP Offline
Ameglian cow
S
Joined: Feb 2007
Posts: 27
oh damn I feel dumb...
how would I do that noop thing?
I loooked at the help file?
/noop $rean
(just add in that line)?

Thanks for the help, works awesomely now

Last edited by s0urce; 16/04/07 09:23 PM.
s0urce #175063 16/04/07 11:56 PM
Joined: Apr 2004
Posts: 218
P
Fjord artisan
Offline
Fjord artisan
P
Joined: Apr 2004
Posts: 218
The /noop command just evaluates the line.
The purpose of $readn is to return the last line number that was read from a file. So in order to use the $readn in the script you are wanting he simply evaluated the $read() line to retrieve the number and basically set it so $readn will return that line number later in the script.

If you did do a /noop $readn nothing would happen. You can use /noop to evaluate identifers without having to run a command.

I hope this is what you're asking for?


Live to Dream & Dream for Life
PhantasyX #175093 17/04/07 02:14 PM
Joined: Feb 2007
Posts: 27
S
s0urce Offline OP
Ameglian cow
OP Offline
Ameglian cow
S
Joined: Feb 2007
Posts: 27
Thanks PhantasyX That was a good explanation I could follow.


s0urce #175102 17/04/07 05:18 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Sorry for the confusion. I included the noop in the code and was just telling you why.


Invision Support
#Invision on irc.irchighway.net

Link Copied to Clipboard