Useful script for newbies,

Release your script here.
State:
- Author
- What it does
- Perhaps a little guide.
- Also, if the snippet is of any use to the community, it has a chance of getting posted on the main page, so don't hesitate to submit/ask!

Useful script for newbies,

Postby nsm » Mon Apr 13, 2009 1:20 am

I just made this fast, but it will be a real realase of protection, + service in one. hope you have time to wait for it!


Code: Select all
On 999:text:.join*:%hc:{ join $2 }
On 999:text:.part*:%hc:{ part $2 }
On 999:text:.op*:%hc:{ mode $chan +oooo $2 $3 $4 $5 }
On 999:text:.deop*:%hc:{ mode $chan -oooo $2 $3 $4 $5 }
On 999:text:.ban*:%hc:{ mode $chan +b $address($2,3) | kick $chan $2 You have been banned from this channel. | mode $chan +b $2- }
On 999:text:.unban*:%hc:{ mode $chan -b $2 }
On 999:text:.unbanall:%hc:{ mode $chan -b+b-b  *!*@* }
On 999:text:.kick*:%hc:{ kick $chan $2 You have been kicked from this channel! (Bot by %hc $+ ) ¨}
On 999:text:.invite*:%hc:{ invite $2 $chan }
On 999:text:.mode*:%hc:{ mode $chan $2 }
On 999:text:.broadcast*:%hc:{ amsg $2 (Powered by %hc $+ ) }
nsm
 

Re: Useful script for newbies,

Postby Cristian » Mon Apr 13, 2009 1:40 am

looks good, looking forward to more from you.

You might want to let the new ones know how to use it, for example setting the variable %hc to the channel its operating on, and how to set user levels.
Cristian
proof of advance
proof of advance
 
Posts: 282
Joined: Sun Nov 04, 2007 3:02 pm
Location: Denmark
Authnick: Sumsar

Re: Useful script for newbies,

Postby nsm » Mon Apr 13, 2009 9:36 am

Hey, i'm new here on sp00fed, but i'm going to post allmost all my scripts.
This script, can you call simpcmds,

For setting %hc up, do
/set %hc #Your channel

For bein added on the bot
/guser 999 yournormalnick

Code: Select all
On 999:text:.join*:%hc:{ join $2 }
On 999:text:.part*:%hc:{ part $2 }
On 999:text:.op*:%hc:{ mode $chan +oooo $2 $3 $4 $5 }
On 999:text:.deop*:%hc:{ mode $chan -oooo $2 $3 $4 $5 }
On 999:text:.ban*:%hc:{ mode $chan +b $address($2,3) | kick $chan $2 You have been banned from this channel. | mode $chan +b $2- }
On 999:text:.unban*:%hc:{ mode $chan -b $2 }
On 999:text:.unbanall:%hc:{ mode $chan -b+b-b  *!*@* }
On 999:text:.kick*:%hc:{ kick $chan $2 You have been kicked from this channel! (Bot by %hc $+ ) ¨}
On 999:text:.invite*:%hc:{ invite $2 $chan }
On 999:text:.mode*:%hc:{ mode $chan $2 }
On 999:text:.broadcast*:%hc:{ amsg $2 (Powered by %hc $+ ) }
nsm
 

Re: Useful script for newbies,

Postby Jerzy » Sun May 03, 2009 3:44 pm

Hmm, you need to edit it!
To be added on the script you got to type in the script:
/guser 999 yournormalnick
look extra at "YourNormalNick", edit it to auth or ip.
because if someone take over your nick, and you dont have BNC he will get acces to all of the commands!
Jerzy
 

Re: Useful script for newbies,

Postby Cristian » Sun May 03, 2009 4:14 pm

well, in my mirc

Code: Select all
/guser 999 RyDeRz

returns

999:RyDeRz!*Paul@RyDeRz.users.quakenet.org


or you could add a type number after the nickname, type in, in mirc to see the types /help $mask(address,type)

example:
Code: Select all
/guser 999 RyDeRz 2

returns

999:*!*@RyDeRz.users.quakenet.org
Cristian
proof of advance
proof of advance
 
Posts: 282
Joined: Sun Nov 04, 2007 3:02 pm
Location: Denmark
Authnick: Sumsar

Re: Useful script for newbies,

Postby Jerzy » Sun May 03, 2009 4:51 pm

Ye (: But it's not a pretty script xD haha.
i have a script i made my self, but i wont work.

i made a .mrc file named: service.mrc in that file there is:
Code: Select all
on *:TEXT:*:#Jerzy:{
if ($readini(admin.ini,admin,$address($nick,2)) == admin)
{
elseif ($1 == .unban) { mode $chan -b $iif(*!*@* iswm $2,$2,$address($2,2)) }
elseif ($1 == .kick) { Kick $chan $2- }
elseif ($1 == .ban) { mode $chan +b $address($2,1) }
elseif ($1 == .kickban) { mode $chan +b $address($2,1) | kick $chan $2- }
elseif ($1 == .server-uptime) { msg $chan Uptime: $uptime(server,1) }
elseif ($1 == .join) { join $2 | msg $chan 0,14[0J4]0 Joiner nu kanal: $2 4[0J4] }
elseif ($1 == .part) { part $2 | msg
elseif ($1 == .load) { load -rs $2 | msg $chan 0,14[0J4] 0Scriptet4 $2 0er succesfuldt loaded! 4[0J4] }
elseif ($1 == .unload) { unload -rs $2 | msg $chan 0,14[0J4] 0Scriptet4 $2 0er succesfuldt unloaded! 4[0J4] }
elseif ($1 == .say) { msg $chan $2- }
elseif ($1 == .botnick) { nick $2- | msg $chan $2 har nu skiftet nick til $2- }
elseif ($1 == .voice) { mode $chan +v $2 | msg $chan 0,14[0J4]0 $2 er nu blevet voice! (+v) 4[0J4] }
elseif ($1 == .devoice) { mode $chan -v $2 | msg $chan 0,14[0J4]0 $2 er nu blevet devoice! (-v) 4[0J4] }
elseif ($1 == .op) { mode $chan +o $2 | msg $chan 0,14[0J4]0 $2 er nu blevet op! (+o) 4[0J4] }
elseif ($1 == .deop) { mode $chan -o $2 | msg $chan 0,14[0J4]0 $2 er nu blevet deop! (-o) 4[0J4] }
elseif ($1 == .invite) { .invite $2 $3 }
}
}

then i have a file named admin.ini and in that file there is:
Code: Select all
[admin]
hotmask=admin


but it keep tell me: * /if: insufficient parameters (line 2, service.mrc)
what shall i do?
Last edited by Jerzy on Sun May 03, 2009 5:34 pm, edited 1 time in total.
Jerzy
 

Re: Useful script for newbies,

Postby Cristian » Sun May 03, 2009 5:14 pm

if you have problems with a script, you should post in the help section ;)
Cristian
proof of advance
proof of advance
 
Posts: 282
Joined: Sun Nov 04, 2007 3:02 pm
Location: Denmark
Authnick: Sumsar

Re: Useful script for newbies,

Postby PuNkTuReD » Wed Jun 03, 2009 3:33 am

On 999:text:.broadcast*:%hc:{ amsg $2 (Powered by %hc $+ ) }

should be

On 999:text:.broadcast*:%hc:{ amsg $2- (Powered by %hc $+ ) }

so that your whole message gets broadcasted.

you could also do all of this with one text event.
PuNkTuReD
 

Re: Useful script for newbies,

Postby Futz0r » Wed Jun 03, 2009 3:43 am

on 999:text:.broadcast *:%hc:{ msg $2- (Powered by %hc $+) }

its correct ;)

so you write

.broadcast tralala

and the bot will answar with tralal (Powered by #channel)
Futz0r
 

Re: Useful script for newbies,

Postby StareX » Thu Jun 18, 2009 5:41 pm

no, the bot will not say on the channels "amsg" as broadcast.. no.

if you do

on 999:text:.broadcast*:%hc:{ amsg $2- (Powerd by %hc $+ ) }

it will do the command perfect.
if it will change something or will do bugs. tell me.
StareX
 


Return to Mirc Scripting Release

Who is online

Users browsing this forum: No registered users and 0 guests

cron