Skip to content
General IRCd

help

A TG007 community discussion started by Murda.

Discussion 11 posts
Page 1 of 1
Open
Topic #1864 · 11 published posts · 2,658 views

hey guys

 

need some real help here. im not the best of scripters but i need some help on an auto host. the thing is, i was wondering if it was possible to do a little code which worked when the person who's hostmask is added to the userlist in mirc, when he joins, he types the correct password in a whisper to get his +h. now ive asked round but no one seems to reall know so i thought id ask here see if anyone had the code or had any idea's oops.gif

i'll have a crack at this. Haven't actually been around IRCD but it should be the same thing.

 

replace the things in brackets with what you want it as

 

on <level>:TEXT:*:?: { var %t $strip($1-) | if (%t == %roompass) { /mode +h $nick } }

 

remember to put that into remotes, and to set %roompass in your variables as what you want the speicial code to be. so in the variables, it would be something like %roompass 12345

 

it seems very basic, but from what i can, it does answer your question.

 

on <level>:TEXT:*:?: { if ($strip($1-) == %roompass) { /mode +h $nick } }

Felt like being pidantic with TGK's code laugh.gif

Edited Nov 11, 2004 6:19 PM by Cleric xtx

 

thanx guys for the reply, but ive tried it and neither of them work for some reason, been trying to figure it out and its reckin my head lol_sign.gif

on *:text:*:?:{
 if ($strip($1-) == <password>) {
   var %i = 1
   while (%i <= $comchan($nick,0)) {
     if ($comchan($nick,%i).op) { mode $comchan($nick,%i) +o $nick }
     inc %i
   }
 }
}

 

I presume you wanted to give them an @ (+o, operator)

Edited Dec 5, 2004 9:50 AM by tidy trax

on thiernick:TEXT:thierpass:?:{ /mode $comchan($nick,1) +o $nick | closemsg $nick }

this would make it so they can also each have thier own pass. that way you can ramove one person without having to change the pass for the whole room. just add a new line for each user

Edited Jun 17, 2005 11:14 PM by Rudeboy

Rudeboy, there is no $chan in a query.

on *:text:*:?:{
 if ($strip($1-) == <password>) {
   var %i = 1
   while (%i <= $comchan($nick,0)) {
     if ($comchan($nick,%i).op) { mode $comchan($nick,%i) +o $nick }
     inc %i
   }
 }
}

only problem with the code tidy gave , is if you were in say 2 rooms and the other person was too, it would host them in both rooms

 

apart from that the code should work

My code does NOT have bugs. It just develops random features.

thanx you guys that worked perfect apart from what ozzy said that it hosts in all rooms which is going to be a pain, is there any way round it, if not its all kool

 

Thanx again

Since there's no $chan in a query, which channel would you like to op them in? 1st? 2nd? 3rd?

Just add a # Name ........... if ($nick << nick to op ISIN chan for op >>$chan)

 

\\=========//

CRASH

\\==============//