mIRC Home    About    Download    Register    News    Help

Topic Options
#148718 - 10/05/06 04:12 AM auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
ok i wana make an auto op list but i dont know how my friend told me get my bot to read a file and the file would have a list of names to auto op but i dont know how to do all that can someone please help me

Top
#148719 - 10/05/06 04:15 AM Re: auto op
hixxy Offline
Hoopy frood

Registered: 06/09/05
Posts: 2876
Take a look at the /aop command.. /help /aop

Top
#148720 - 10/05/06 04:54 AM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
i did just made it worse

Top
#148721 - 10/05/06 05:07 AM Re: auto op
MikeChat Offline
Hoopy frood

Registered: 12/12/02
Posts: 1245
Loc: California, doooood
typing /help /aop
that made things worse?
maybe you can tells us what you did exactly

Quote:

Control

The Control dialog performs functions related to channel and user control.

Auto-Op
If a user joins a channel where you have Ops and that user's address is listed in the auto-op list, they will be given Op status. You can add an address to the list in the following format:

nick!userid@host,#channel1,#channel2

On IRC, user addresses are specified in the format:

nick!userid@host

So if my nickname is MadGoat and my address is khaled@mirc.com then to put me in your list, you would use:

madgoat!khaled@mirc.com

If I change nicknames a lot, then you would use:

*!khaled@mirc.com

If I change my nickname and userid a lot, then:

*!*@mirc.com

The /aop command

/aop [-rw] <on|off|nick/address> [#channel1,#channel2,...] [type] [network]

The -r switch indicates that the address is to be removed.
The -w switch makes the auto-op apply to any network.

If you do not specify a type then only the users nickname is used. If you specify a type then the users address is looked up via the server.

The $aop identifier returns $true if auto-op is enabled, and $false if it isn't.

The $aop(address/N) identifier returns any matching address in the list, or the Nth address. The .type property returns the list of channels. The .network property returns the associated network, if any.

Top
#148722 - 10/05/06 05:15 AM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
i understand that but ithat would mean i would have to do that for a lot of users i was told that there was a that u can make the bot read a file and in that file it has list of names that are to be oped

Top
#148723 - 10/05/06 10:04 AM Re: auto op
hixxy Offline
Hoopy frood

Registered: 06/09/05
Posts: 2876
Sure, try this:

Code:
on @*:join:#:{
  if ($read($+($scriptdirops\,$mkfn($chan),.txt),nw,$nick)) || ($read($scriptdirops\globals.txt,nw,$nick)) mode $chan +o $nick
}


Create an ops\ directory wherever this script is, then create a .txt file for each channel you want to have ops for. So if you wanted to have ops for #x, you want create #x.txt and type the ops for that channel in there. For global ops (all channels) you would write their names in globals.txt.

Top
#148724 - 10/05/06 05:22 PM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
so now i need to put the location of the file C: and all that

Top
#148725 - 10/05/06 05:29 PM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
ok my channel name is #TheUnKnowns so i need to make a folder that says op and then inside the file op i need to make a text file called TheUnKnowns
also with that scrpt u gave me it needs to go into the remote section right?

i know i sound stupid but i wana make sure i do this right

Top
#148726 - 10/05/06 05:57 PM Re: auto op
RedDevilUK Offline
Ameglian cow

Registered: 08/05/06
Posts: 32
Code:
on @*:join:#TheUnKnowns:{  if ($read($+($scriptdirops\,$mkfn($chan),.txt),nw,$nick)) || ($read($scriptdirops\op\TheUnKnowns.txt,nw,$nick)) mode $chan +o $nick
}  


And yes paste it into the end of your remotes


Edited by RedDevilUK (10/05/06 06:01 PM)

Top
#148727 - 10/05/06 06:19 PM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
redevilUK ur script isnt workin

Top
#148728 - 10/05/06 06:23 PM Re: auto op
bojak71730 Offline
Babel fish

Registered: 10/10/05
Posts: 54
hixxy im sure ur script works i must be editing it wrong or doing somthing wrong so can u help me?

Top
#148729 - 10/05/06 07:35 PM Re: auto op
MikeChat Offline
Hoopy frood

Registered: 12/12/02
Posts: 1245
Loc: California, doooood
try this way of looking at the
Code:
on @*:join:#:{
  if ($read($+($scriptdirops\,$mkfn($chan),.txt),nw,$nick)) mode $chan +o $nick
  elseif ($read($scriptdirops\globals.txt,nw,$nick)) mode $chan +o $nick
}
or look at it this way
If mIRC is in c:\mIRC\
and the script is in the main folder, he said to make a subfolder 
c:\mirc\ops\
and in the folder c:\mirc\ops\ put the ops text #TheUnKnowns.txt 
with all your ops listed in that text (c:\mirc\ops\#TheUnKnowns.txt)

on @*:join:#:{
  if ($read($+($scriptdirops\#TheUnKnowns,.txt),nw,$nick)) mode $chan +o $nick
}

this one would be for multiple channels:
If mIRC is in c:\mIRC\
and the script is in the main folder, he said to make a subfolder 
c:\mirc\ops\
and in the folder c:\mirc\ops\ put the ops text globals.txt 
with all your ops listed in that text (c:\mirc\ops\globals.txt)

on @*:join:#:{
  if ($read($scriptdirops\globals.txt,nw,$nick)) mode $chan +o $nick
}

Top
#148730 - 11/05/06 02:58 AM Re: auto op
hixxy Offline
Hoopy frood

Registered: 06/09/05
Posts: 2876
If the script is in c:\mirc you should create the c:\mirc\ops directory and then the c:\mirc\ops\#TheUnknown.txt file with the list of ops for that channel.

If the script is in c:\program files\mirc you should create the c:\program files\mirc\ops directory and then the c:\program files\mirc\ops\#TheUnknown.txt file with the list of ops for that channel.

If you want I could write something quickly to let you edit the list of ops automatically without having to create a new file manually each time.

Top
#148731 - 11/05/06 03:14 PM Re: auto op
genius_at_work Offline
Hoopy frood

Registered: 08/10/05
Posts: 1741
If you want to easily edit/add the files, just add this alias to your remotes file:
Code:
alias editops {
  var %chan = $active
  if (#* iswm $1) %chan = $1
  else {
  echo -a Syntax: /editops #channel
  return
  }
  run $+($scriptdirops\,$mkfn(%chan),.txt)
}

(untested)

To edit a file, do one of the following things:

/join the channel you want to edit, and make its window active, then type /editops

-or-

Type /editops #channel from any window.

---

Your default .txt editing program should be opened with the correct file in it. Just edit the file and save it.

-genius_at_work

Top