mIRC Home    About    Download    Register    News    Help

Print Thread
#127759 16/08/05 05:22 PM
Joined: Aug 2005
Posts: 11
F
fobiC Offline OP
Pikka bird
OP Offline
Pikka bird
F
Joined: Aug 2005
Posts: 11
Can someone have 2 users in a bot? if i want someone to be able to use some scripts that noone can use. and i dont want him to be able to use the op scripts.. I'm sorry that i have so bad english..

#127760 16/08/05 05:31 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
You can have all kinds of users with all kinds of priveledges.

A simple thing to do is to set you as "admin" level... perhaps level 1000 in your bot's user list. Set ops at perhaps level 500. Set someone who you want to have a certain ability at level 250.

You can then do something like this:

on 1000:text:!quit:*: { quit }
on 500:text:!opme:*: { /mode $chan +o $nick }
on 250:text:!voiceme:*: { /mode $chan +v $nick }

That's just one example of how you can do things. Anyone level 1000 (admin) could do all three things. Anyone level 500 (ops) could do !opme or !voiceme and anyone level 250 could do just the !voiceme command.

To add users to your user list, you can do this in the bot:

/auser <level> <address>

Example:

/auser 500 Riamus!Riamus@myhost.com

Just change the address mask to what you want to use... like *!*@host.com or Riamus!*@host.com or whatever.


If you want another way to do it, please include details of what you're trying to do and we can show you another method that may be more appropriate. smile


Invision Support
#Invision on irc.irchighway.net
#127761 16/08/05 05:46 PM
Joined: Aug 2005
Posts: 11
F
fobiC Offline OP
Pikka bird
OP Offline
Pikka bird
F
Joined: Aug 2005
Posts: 11
I want to do so a person can use +c and -c commands but and then i want to do so he can have for example 250.. and both at the same time..

#127762 16/08/05 06:06 PM
Joined: Aug 2005
Posts: 128
S
Vogon poet
Offline
Vogon poet
S
Joined: Aug 2005
Posts: 128
Quote:
I want to do so a person can use +c and -c commands but and then i want to do so he can have for example 250.. and both at the same time..

I don't understand what you want to say. Please try to explain detalied. Also we don't know what you want the commands +c or -c to do.

I don't know what you wanted to say, but I'll try to help you anyway.
Not sure that's what you wanted, but here's a code for you:
Code:
on 250:text:+c:#:commands here
on 250:text:-c:#:commands here

#127763 16/08/05 06:09 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Well, first off, go through any bot scripts you have and change your ops-only or owner-only commands to a higher rank like I showed above. Then, put your ops and you in your bot's user list with the ranks I mentioned (or whatever you want to use).

Next, you can just do something like this for any commands you want this level 250 person to use:

Code:
on 250:text:*:*:{
  if ($1 == !command) { do stuff }
  elseif ($1 == !command2) { do stuff }
  elseif ($1 == !command3) { do stuff }
}


Since I don't know the -/+ c command format, I'll give you an example for if you want to allow a level 250 to do !ban:

Code:
on 250:text:*:*:{
  if ($1 == !ban &amp;&amp; $2 ison $chan &amp;&amp; $me isop $chan) { 
    ban $chan $2
  }
  elseif ($1 == !ban &amp;&amp; $3 ison $2 &amp;&amp; $me isop $2) {
    ban $2 $3
  }
}


Use: !ban <nick>
Use2: !ban <chan> <nick>

As an explanation of that example, I include the "$me isop" since the bot needs to have op status to do a ban command and this will make it only work if the bot is opped. The 250 makes it so you have to be at least level 250 to have access to the command.

$1 is the command (!ban).
$2 is either a nick or a channel depending if you're putting a channel with the nick.
$3 is there if a channel is entered as $2.

The reason there is the option is so someone can use !ban <nick> from within a channel and it will ban them in that channel, and so someone can also use !ban <chan> <nick> from within a query window and it will ban the person in the specified channel.

If you can't figure out how to change this to work with -/+ c, then please include the format for using -/+ c and I'll write it up for you if someone doesn't beat me to it. smile


Invision Support
#Invision on irc.irchighway.net
#127764 16/08/05 06:11 PM
Joined: Aug 2005
Posts: 11
F
fobiC Offline OP
Pikka bird
OP Offline
Pikka bird
F
Joined: Aug 2005
Posts: 11
blah, I cant explain.. 14 years old swedish boy, it isn't very easy.. but I can try once again.. look here.. on c:text:!c &:#:{ mode $chan +c } i want to do so that one person can use this script.. only that person.. and then i want him to be able to use on 250: scripts too.. the problem is that i dont know if u can have 2 users.. in the users directory.. or what it is called..

#127765 16/08/05 06:14 PM
Joined: Apr 2003
Posts: 701
K
Hoopy frood
Offline
Hoopy frood
K
Joined: Apr 2003
Posts: 701
if that level cannot be put in the order 1000,500,250, .. then use a named level. If you want him to be able to hand out +c and get voice, use

in Users tab:
250,givesc:nick!ident@ip.address.com

in Remotes:
on givesc:TEXT:!+c &:#channelname: mode $chan +c $2

#127766 16/08/05 06:23 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Yes, you can have 2 people with the same rank in the user list.

Try one of these:

If you want the one special person to have access to 250 & the +/- c command and you want someone at level 250 to also have access to both, do this:

on 250:text:+c:#:{ mode $chan +c }
on 250:text:-c:#:{ mode $chan -c }
on 250:text:!command:#: { do commands for all level 250 commands }

In User list, have:

250:Address1
250:Address2

This way, your special user and all level 250 users have the same commands (including +/- c command).

----------

If you instead want it so that the special user can do both 250 commands and the +/- c command and you want 250 level users to not have access to the +/- c command but have access to level 250 commands, then do this:

on 255:text:+c:#:{ mode $chan +c }
on 255:text:-c:#:{ mode $chan -c }
on 250:text:!command:#: { do commands for level 250 users }

255:Address1
250:Address2

Your special user would be level 255 and could do level 250 commands and also the +/- c command while not allowing the level 250 users to do the +/- c command.

===========

As a note, your example showed:

on c:text:!c &:#:{ mode $chan +c }

You can use a number instead of "c" in "on c". If not, then you need to add your user to the list with multiple ranks like this:

/auser 250,c Address

"!c &" ... This would trigger if someone typed !c followed by a word (&). Since you're not using a $2 anywhere, you probably don't have a need for a word after the !c. So, you could just use !c or you can use +c or whatever you want for the trigger. Note that if the word following !c was supposed to be the channel name, then you need to replace $chan in your example with $2.

Btw, what's the +/- c command for? I can't test it where I am right now. Is it to allow colors or something?


Invision Support
#Invision on irc.irchighway.net
#127767 21/08/05 12:45 AM
Joined: Aug 2004
Posts: 26
M
Ameglian cow
Offline
Ameglian cow
M
Joined: Aug 2004
Posts: 26
When the person is online, type "//echo $address(InsertTheirNicknameHere,3)" Copy that text, and then use:
Code:
on *:TEXT:!c:#: if ($address($nick,3) ==  ThisIsThePlaceYouPutTheCopiedText) {  /mode $chan +c }


Link Copied to Clipboard