mIRC Home    About    Download    Register    News    Help

Print Thread
#81093 28/04/04 12:28 PM
Joined: Apr 2004
Posts: 2
U
uid Offline OP
Bowl of petunias
OP Offline
Bowl of petunias
U
Joined: Apr 2004
Posts: 2
Hi!
I'm using mIRC 6.14 and I want to have a script that does this:
When I write in a channel and sends my msg I want the script to automaticly add a dot after the thing I have written.

Example:
In the channel "#oki" I write "ok, thanks" and sends it and the scripts adds a dot to the quote and when everybody recieves it it looks like this - "ok, thanks."

Is that possible? I hope you understood what i meant.

Joined: Dec 2002
Posts: 1,321
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Dec 2002
Posts: 1,321
Assuming you have no other on INPUT events in your remote scripts (Alt+R), adding the following snippet will do what you need. If you do have other on INPUT events, you will have to modify them to include adding the $+ . as shown in each event.

on *:INPUT:#: if /* !iswm $1 && !$ctrlenter { say $1- $+ . | halt }


DALnet: #HelpDesk and #m[color:#FF0000]IR[color:#EEEE00]C
Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
i'm guessing you already knew, but not everyone uses / as the command prefix, this would be better imo:

Code:
on *:INPUT:#: if $left($1,1) != $readini($mircini,text,commandchar) && !$ctrlenter { say $1- $+ . | halt }


New username: hixxy
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
I'm guessing you don't know that no matter what is set in options, / is always a command prefix.
  • if $left($1,1) !isin / $readini($mircini,text,commandchar) && ...


However, i am of the opinion that scripting for the obscure is unnecessary, the very few people who have a different commandchar should know they have set one, and so adjust such a script accordinglly.

Joined: Aug 2003
Posts: 325
W
Fjord artisan
Offline
Fjord artisan
W
Joined: Aug 2003
Posts: 325
Quote:
on *:INPUT:#: if /* !iswm $1 && !$ctrlenter { say $1- $+ . | halt }

Code:
on *:INPUT:#: if /* !iswm $1 && !$ctrlenter && $right($strip($1-),1) != . { say $1- $+ . | halt }

smile Just in case they include the . themselves, it won't add another one. grin

And the "/" debate reminds me of another feature request...

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
i didn't know that, thanks smile


New username: hixxy

Link Copied to Clipboard