This My First Snippet
I have not yet made any other
This is my first time
So plz forgive me if any mistake is there in my script
And the scanbug cmd does not repaid the bugs it just send to the channel that it have been fixed sry for that
on *:TEXT:!trade*:#: {
if (!$2) || (!$3) || (!$4) describe $chan : Syntax : !Trade [Country] [Object Or Thing , You Want To Trade] [Days]
else {
describe $chan : $nick is Trading to $2 for selling $3 for $4 day(s)
describe $chan : $nick is away . reason : Trading to $2
}
}
on *:Text:!brejoin:#:{
if ( $nick isop $chan ) cycle $chan
}
on *:TEXT:!qbot:#: {
if ($nick($chan,$nick,&~))
msg $chan ---> Echo Bot Disconnected <--
{ /quit Disconnected }
}
on *:Text:!scanbug:#: {
describe $chan : Scanning for bugs
timer 1 2 msg $chan 10%
timer 1 4 msg $chan 20%
timer 1 8 msg $chan 30%
timer 1 13 msg $chan 70%
timer 1 15 msg $chan 95%
timer 1 18 msg $chan 100% . Completed Scanning
timer 1 19 msg $chan Fixing Errors
timer 1 22 msg $chan Errors Fixed
timer 1 23 msg $chan Thanks $nick For Scanning And Fixing The Bugs
}
guys i have an irc channel in that many other cmds are there you may plz visit it
http://liberty-unleashed.co.uk:9090/?channels=Dany
@Sorasyn I think $nick()
supports nick prefixes too but as an undocumented feature. I might be wrong but investigate for yourself.
if (!$2) || (!$3) || (!$4)
could be shortened to if (!$4)
because if the fourth token exists then the second and third must exist.
just be aware that !$4
means the fourth token could be $null
, 0
, or $false
. if the command needs a specific type of input you might want to use comparisons such as isnum
(for days).
$chan
and #
are interchangeable as well, just a tip.
Keep it up.
I'm having a hard time believing this actually runs as intended just from the way it's setup.
if ($nick($chan,$nick,&~))
msg $chan ---> Echo Bot Disconnected <--
{ /quit Disconnected }
Mainly because you initiate a bracket out of the blue with no preceding statement.
$nick(#,N/Nick,aohvr) only supports a mixture of "aohvr" a = all nicks, o = ops, h = halfop, and so on. However to get rank symbols like you've shown is an easy adjustment: $nick($chan,$nick).pnick "The pnick property returns the nickname in a .@%+nick format." Right out of the help file. :)
This is how it should look.
if ($nick($chan,$nick,&~)) {
msg $chan ---> Echo Bot Disconnected <---
quit Disconnected
}
Just a few suggestions, hope it helps.