mIRC Home    About    Download    Register    News    Help

Print Thread
#115136 22/03/05 04:54 PM
O
omen_253
omen_253
O
I know this has been asked before i have looked and cant seem to find one ...
Hope someone can help...
What i'm looking for is script so i can make my bot /join /part rooms in pm , and only by me......
if able to add more ppl in too...
thx for your help and time here smile

S
Stranger_Lv
Stranger_Lv
S
the easyest way is to use hostmasks instead of identify.
try this (ALT+R)->

Code:
 
on 2:text:!join*:?:join $2
on 2:text:!part*:?:part $2
 


to add new users, type /auser 2 *!*@users.host/ip

Joined: Aug 2004
Posts: 7,168
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,168
This will allow you to specify one or more channels to part/join. or, if no channel is specified, then nothing will happen in the join, or will part all channels...Didn't include a way to allow for others, yet...but will think about it, and post when I have something.


Code:
on *:text:!part *:?:{
if ($nick == $me) { 
if (!$2) {
var %a = $comchan($me,0)
while (%a) { .part $comchan($me,%a) }
dec %a
}
else {
var %a = $2-
while (%a) {
if <bot> isin $gettok(%a,1,32) { .part $v2 }
}
var %a = $remtok(%a,$v2,1,32)
}
}
}

on *:text:!join *:?:{
if ($nick == $me) { 
if ($2) {
var %a = $2-
while (%a) {
if <bot> !isin $gettok(%a,1,32) { .join $v2 }
}
var %a = $remtok(%a,$v2,1,32)
}
}
}
 

Last edited by RusselB; 22/03/05 09:01 PM.
Joined: Mar 2005
Posts: 420
X
Fjord artisan
Offline
Fjord artisan
X
Joined: Mar 2005
Posts: 420
Quote:
the easyest way is to use hostmasks instead of identify.
try this (ALT+R)->

Code:
 
on 2:text:!join*:?:join $2
on 2:text:!part*:?:part $2
 


to add new users, type /auser 2 *!*@users.host/ip


You could also put a check if the bot is in the channel or not and make sure that a second parameter was entered.

Code:
 on 2:text:!join*:?: {
 if ($2) && ($2 !ischan) join $2
}

on 2:text:!part*:?:{
if ($2) && ($2 ischan) part $2
} 

Joined: Aug 2004
Posts: 7,168
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,168
All commands have been set up so that they will only work if you or another user with level 5 can use them. You'll have to substitute your bots nick where I have <bot> in the script.


Code:
on *:text:!adduser *:*:{
if ($nick == $me) || $ulevel == 5 {
if (!$2) .msg $nick I need a name to add to the list
else {
 var %a = $2-
while (%a) {
.auser 5 $gettok(%a,1,32)
var %a = $remtok(%a,$gettok(%a,1,32),1,32)
}
}
}
}

on *:text:!part *:?:{
if ($nick == $me) || $ulevel == 5 { 
if (!$2) {
var %a = $comchan($me,0)
while (%a) { .part $comchan($me,%a) }
dec %a
}
else {
var %a = $2-
while (%a) {
if &lt;bot&gt; isin $gettok(%a,1,32) { .part $v2 }
}
var %a = $remtok(%a,$v2,1,32)
}
}
}

on *:text:!join *:?:{
if ($nick == $me) || $ulevel == 5 { 
if (!$2) .msg $nick I need a name to add to the list
else {
var %a = $2-
while (%a) {
if ($gettok(%a,1,32) ischan) &amp;&amp; (&lt;bot&gt; !isin $gettok(%a,1,32)) { .join $gettok(%a,1,32) }
}
var %a = $remtok(%a,$v2,1,32)
}
}
}
 

Last edited by RusselB; 23/03/05 12:20 AM.
P
Piku
Piku
P
;this is for join a channel of all rooms.
on 1:join:#:{
if ( $nick == $me ) /msg $chan Good Morning Room
else /msg $chan $nick Welcome To This Rom
}
;you can do it in your own room. like this...
on 1:join:#mIRC,#Help:{
if ( $nick == $me ) /msg $chan Good Morning Room
else /msg $chan $nick Welcome To This Rom
}

;this is for part a channel of all rooms.
on 1:part:#:{
if ( $nick == $me ) /msg $chan I am loving it
else /msg $chan $nick Thank's for joining with us.
}
;you can do it in your own room. like this...
on 1:part:#mIRC,#Help:{
if ( $nick == $me ) /msg $chan I am loving it...
else /msg $chan $nick Thanks for joining with us
}

Joined: Mar 2005
Posts: 420
X
Fjord artisan
Offline
Fjord artisan
X
Joined: Mar 2005
Posts: 420
Quote:
I know this has been asked before i have looked and cant seem to find one ...
Hope someone can help...
What i'm looking for is script so i can make my bot /join /part rooms in pm , and only by me......
if able to add more ppl in too...
thx for your help and time here smile


He wants to make the bot join/part channels. Please read the topic before posting.

O
omen_253
omen_253
O
Thx very much , will test it tonite after work ..
thx agian , and thx to all that posted ..

smile

O
omen_253
omen_253
O
I cant seem to get any of them to work for me frown
I must be doing something wroung ...
I type :
nemo_253 !join #warezrus
!join nemo_253 #warezrus
!join #warezrus nemo_253
/notice nemo_253 !join #warezrus

Thx for your help and time here...

C
CtrlAltDel
CtrlAltDel
C
um .. /msg instead of /notice ?¿?

not that I know anything ...

Joined: Mar 2005
Posts: 420
X
Fjord artisan
Offline
Fjord artisan
X
Joined: Mar 2005
Posts: 420
Use /msg BOTNAME !join #Channel


Link Copied to Clipboard