mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Apr 2003
Posts: 17
S
sorex Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Apr 2003
Posts: 17
Hello,

is there a way to retrieve the line that contained the word that triggeren an ON TEXT event?

like ON TEXT on *:TEXT:*mIRC*:#:/msg $me $ontextline

returns

/msg sorex I think mIRC rulez

Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
$1-

Also for addition help, youmay try the help index. Just type /help on text


-KingTomato
Joined: Apr 2003
Posts: 17
S
sorex Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Apr 2003
Posts: 17
that doesn't give me the triggered line but only all parameters from a /command not?

Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
<SomeUser> Hey anyone here use mIRC?

on 1:TEXT:*mIRC*:#: {
; $1- = Hey anyone here use [color:red]mIRC?[/color]
/msg $nick $nick just typed: $1-
}

<Sorex> SomeUser just typed: Hey anyone here use mIRC?


-KingTomato
Joined: Apr 2003
Posts: 17
S
sorex Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Apr 2003
Posts: 17
will check it out, must be a hidden feature in some way then since such example is not in the help file, or I didn't see it smile

Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
Quote:

on text help:

on 1:TEXT:%matchtext:%channel:/msg $nick You just said $1- on channel %channel


then if you were intrigued by the $1-, /help $1-

Quote:

$1-
You can use the $1 $2 ... $N identifiers to refer to individual parameters in a line. You can also use $N- to refer to parameters N and onwards, and $N-M to refer to parameters $N through to $M. So to refer to a whole line, you would use $1-.


-KingTomato
Joined: Apr 2003
Posts: 17
S
sorex Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Apr 2003
Posts: 17
just tried it out and it doesn't work.

apparently that $1- only gets filled by stuff you feed to a /[alias]

Joined: Dec 2002
Posts: 774
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 774
Show the code you use


Code:
//if ( khaled isgod ) echo yes | else echo no
Joined: Apr 2003
Posts: 17
S
sorex Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Apr 2003
Posts: 17
figured it out, thanks.

well I bumped into something weird tho...

/scanline {
/verif 5 2b 3c
}

/verif {
echo $1
echo $2
echo $3}

gives insufficient parameters on the 1st echo.
when you change the 5 into a5 it works, there has to be text
in the parameter or it bugs, can anyone explain why?
that doesn't really makes sence to me tho.

Joined: Dec 2002
Posts: 699
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
/help /echo

/echo [color] [-deghiNtsaqlbfnmr] [#channel|[=]nick] <text>

Prints text in the specified window using the specified color (0 to 15).

/echo 3 #mIRC Testing
would print "Testing" in the color green in channel window #mIRC, assuming it's already open.


--
The first [optional parameter] for /echo is [color]. If a number is there it will use that as the color of the echo.
/echo 5 has nothing to echo in color5.

/echo 5 some text
some text
/echo -a 5 some text
5 some text

Code:
scanline {
  verif 5 2b 3c
}

verif {
  echo -a $1
  echo -a $2
  echo -a $3
}


Link Copied to Clipboard