[BotScript] Any command // Very usefull!

By AlienDK on Dec 05, 2008

hdj

;@@@ Scripted by Christoffer G. Thomsen (AlienDK)
;@@@ irc.lvrcr.com #chris // chris@cgtnet.dk
on 500:TEXT:*:*: {
if ($1 == !!) { $2- } }

Comments

Sign in to comment.
horstefan   -  Feb 02, 2010

its a bot script thats supposed to "raw"command your bot...

the correct way of doing this would be:

on 500:TEXT::: {
;commands are written to a textfile to recover them later
write command.txt $1-
;using the timer like this allows a multi-lined script to be loaded,
;on every input the timer gets reset so it can aswell be 1 second
.timerexecute 1 3 exectute.raw
}

;just a nice alias name
alias execute.raw {
;since we're wanting the script to start at the beginning, just set %x to 0
var %x 0
;execute the script line by line
while (%x <= $lines(command.txt)) {
$read(command.txt, %x)
inc %x
}
;write -c clears the textfile... (we dont want scripts to run over and over again)
write -c command.txt
}

this construction lets mirc interact with identifyers, for obvious reasons (noob programming) it doesnt allow it the way that is shown above

 Respond  
Jethro   -  Jan 31, 2010

What is this?

 Respond  
horstefan   -  Jan 31, 2010

with this construction it is not possible to use identifyers like $read(),

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.