mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 02:59:01 -04:00
Move chanprotect settings from <options> to <chanprotect>.
(why were they not there in the first place?) Document <chanprotect:setprivsonothers>. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10739 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
adfcfa9dfd
commit
e4c8a90f85
@ -379,28 +379,6 @@
|
||||
# should be suffixed with.
|
||||
suffixpart="\""
|
||||
|
||||
# noservices: With this set to no, when a user joins a empty channel,
|
||||
# the server will set +q on them. If set to yes, it will only set +o
|
||||
# on them until they register the channel.
|
||||
noservices="no"
|
||||
|
||||
# qprefix: Prefix (symbol) to use for +q users.
|
||||
qprefix="~"
|
||||
|
||||
# aprefix: Prefix (symbol) to use for +a users.
|
||||
aprefix="&"
|
||||
|
||||
# deprotectself: If this value is set (true, yes or 1), it will allow
|
||||
# +a and +q users to remove the +a and +q from themselves, otherwise,
|
||||
# the status will have to be removed by services.
|
||||
deprotectself="no"
|
||||
|
||||
# deprotectothers: If this value is set to yes, true, or 1, then any
|
||||
# user with +q or +a may remove the +q or +a from other users.
|
||||
# The default setting is to not enable this feature, so that
|
||||
# only +q may remove +a, and nothing but services may remove +q.
|
||||
deprotectothers="no"
|
||||
|
||||
# syntaxhints: If enabled, if a user fails to send the correct parameters
|
||||
# for a command, the ircd will give back soome help text of what
|
||||
# the correct parameters are
|
||||
|
@ -363,6 +363,32 @@
|
||||
# Chanprotect module: gives +q and +a channel modes
|
||||
#<module name="m_chanprotect.so">
|
||||
|
||||
<chanprotect
|
||||
# noservices: With this set to no, when a user joins a empty channel,
|
||||
# the server will set +q on them. If set to yes, it will only set +o
|
||||
# on them until they register the channel.
|
||||
noservices="no"
|
||||
|
||||
# qprefix: Prefix (symbol) to use for +q users.
|
||||
qprefix="~"
|
||||
|
||||
# aprefix: Prefix (symbol) to use for +a users.
|
||||
aprefix="&"
|
||||
|
||||
# deprotectself: If this value is set (true, yes or 1), it will allow
|
||||
# +a and +q users to remove the +a and +q from themselves, otherwise,
|
||||
# the status will have to be removed by services.
|
||||
deprotectself="yes"
|
||||
|
||||
# deprotectothers: If this value is set to yes, true, or 1, then any
|
||||
# user with +q or +a may remove the +q or +a from other users.
|
||||
deprotectothers="yes"
|
||||
|
||||
# setprivsonothers: If this value is set to yes, true, or 1, then any
|
||||
# user with +q or +a may add the +q or +a to other users.
|
||||
setprivsonothers="yes">
|
||||
|
||||
|
||||
#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
|
||||
# Check module: gives /check
|
||||
# Check is useful for looking up information on channels,
|
||||
|
@ -362,12 +362,12 @@ class ModuleChanProtect : public Module
|
||||
*/
|
||||
ConfigReader Conf(ServerInstance);
|
||||
|
||||
FirstInGetsFounder = Conf.ReadFlag("options", "noservices", 0);
|
||||
FirstInGetsFounder = Conf.ReadFlag("chanprotect", "noservices", 0);
|
||||
|
||||
std::string qpre = Conf.ReadValue("options", "qprefix", 0);
|
||||
std::string qpre = Conf.ReadValue("chanprotect", "qprefix", 0);
|
||||
QPrefix = qpre.empty() ? 0 : qpre[0];
|
||||
|
||||
std::string apre = Conf.ReadValue("options", "aprefix", 0);
|
||||
std::string apre = Conf.ReadValue("chanprotect", "aprefix", 0);
|
||||
APrefix = apre.empty() ? 0 : apre[0];
|
||||
|
||||
if ((APrefix && QPrefix) && APrefix == QPrefix)
|
||||
@ -379,9 +379,9 @@ class ModuleChanProtect : public Module
|
||||
if (cf && ServerInstance->Modes->FindPrefix(QPrefix) == cf)
|
||||
throw ModuleException("Looks like the +q prefix you picked for m_chanprotect is already in use. Pick another.");
|
||||
|
||||
DeprivSelf = Conf.ReadFlag("options","deprotectself", "yes", 0);
|
||||
DeprivOthers = Conf.ReadFlag("options","deprotectothers", "yes", 0);
|
||||
DeprivOthers = Conf.ReadFlag("options","setprivsonothers", "yes", 0);
|
||||
DeprivSelf = Conf.ReadFlag("chanprotect","deprotectself", "yes", 0);
|
||||
DeprivOthers = Conf.ReadFlag("chanprotect","deprotectothers", "yes", 0);
|
||||
DeprivOthers = Conf.ReadFlag("chanprotect","setprivsonothers", "yes", 0);
|
||||
}
|
||||
|
||||
virtual int OnUserPreJoin(User *user, Channel *chan, const char *cname, std::string &privs, const std::string &keygiven)
|
||||
|
Loading…
x
Reference in New Issue
Block a user