holycrap wrote:
...
Some sort of a list (of nicks), and if the nick joined the channel and his/her nick matches the list, the bot will give it op access. The bot checks the nick and not the host of the nick.
Many thanks!

Here's another take on it:
Code: Select all
bind join - "% *" opbylist
proc opbylist {nick uhost handle chan} {
set opfile "scripts/opfile.txt"
set opinfo [open $opfile r]
set data [read -nonewline $opinfo]
close $opinfo
set lines [split $data "\n"]
foreach opcheck $lines {
if {"[string tolower $opcheck]"=="[string tolower $nick]"} {
pushmode $chan +o $nick
}
}
}
See the line: "scripts/opfile.txt" above. You need to create a plain text file, in your scripts directory, named opfile.txt.
(If you wish to keep the file elsewhere, change the path accordingly)
In this file, put one nick per line
When one of these nicks joins, it will be op'd.
With a couple of quick tests, it worked for me.
Caution: this is a really insecure way to op.
But, if I understood your request correctly, this is exactly what you asked for.
Perhaps if you could describe with more detail exactly what you need, we could come up with better ideas for you. What I have done here, .... if you use it, will let anybody get op'd, simply by leaving, changing their nick to a known op's nick that is not in the channel at the moment, and joining again.
I can't see this as a desirable thing.
Is there a reason that you cannot use Eggdrop's built in userlist? (It is secure.)
I see that you specifically mentioned to avoid using hostmask... why?