mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Apr 2015
Posts: 1
T
Mostly harmless
OP Offline
Mostly harmless
T
Joined: Apr 2015
Posts: 1
Hey, sorry this is my first time posting.

I was wondering if there is any possible way to take a segment of someones sentence and write it to a file.

Lets say the giveaway bot has selected a winner - in the chat it will display "Giveaway ended - The winner is Bill". Is there anyway I can get the "The winner is Bill" part of the bots sentence and write it to a file.
When I do the command "!Winner" the bot will say "The winner is Bill" + any other winners from any other giveaways. (If 3 people win it will say "the winner is bill" "The winner is jack" "the winner is aaron" and so on.

Thank you for any help, i'm not even 100% sure if this is possible. Thanks again!

Joined: Feb 2003
Posts: 3,432
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
If the word always are the same, then you can use:$1 $2 $3 $4 , or you also can use $gettok($1- , 1-4 , 32) ..


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }

Link Copied to Clipboard