mirror of
https://github.com/anope/anope.git
synced 2026-06-23 07:26:38 +02:00
Make the language around fantasy commands less weird.
This commit is contained in:
@@ -730,7 +730,7 @@ log
|
||||
*
|
||||
* Available privileges:
|
||||
* botserv/administration - Can view and assign private BotServ bots
|
||||
* botserv/fantasy - Can use fantasy commands without the FANTASIA privilege
|
||||
* botserv/fantasy - Can use fantasy commands without the FANTASY privilege
|
||||
* chanserv/administration - Can modify the settings of any channel (including changing of the owner!)
|
||||
* chanserv/access/list - Can view channel access and akick lists, but not modify them
|
||||
* chanserv/access/modify - Can modify channel access and akick lists, and use /chanserv enforce
|
||||
|
||||
@@ -391,7 +391,7 @@ privilege
|
||||
}
|
||||
|
||||
/*
|
||||
* FANTASIA privilege.
|
||||
* FANTASY privilege.
|
||||
*
|
||||
* Used by botserv/main and chanserv/xop.
|
||||
*
|
||||
@@ -399,7 +399,7 @@ privilege
|
||||
*/
|
||||
privilege
|
||||
{
|
||||
name = "FANTASIA"
|
||||
name = "FANTASY"
|
||||
desc = _("Allowed to use fantasy commands")
|
||||
rank = 30
|
||||
level = 3
|
||||
|
||||
+10
-10
@@ -7,8 +7,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Anope\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-06-12 17:52+0100\n"
|
||||
"PO-Revision-Date: 2024-06-12 17:53+0100\n"
|
||||
"POT-Creation-Date: 2024-06-23 14:15+0100\n"
|
||||
"PO-Revision-Date: 2024-06-23 14:16+0100\n"
|
||||
"Last-Translator: Sadie Powell <sadie@witchery.services>\n"
|
||||
"Language-Team: English\n"
|
||||
"Language: en_US\n"
|
||||
@@ -866,9 +866,9 @@ msgid ""
|
||||
"fantasy commands on a channel when prefixed\n"
|
||||
"with one of the following fantasy characters: %s\n"
|
||||
" \n"
|
||||
"Note that users wanting to use fantaisist\n"
|
||||
"commands MUST have enough access for both\n"
|
||||
"the FANTASIA and the command they are executing."
|
||||
"Note that users wanting to use fantasy commands\n"
|
||||
"MUST have enough access for both the FANTASY\n"
|
||||
"privilege and the command they are executing."
|
||||
msgstr ""
|
||||
" \n"
|
||||
"Enables or disables fantasy mode on a channel.\n"
|
||||
@@ -876,9 +876,9 @@ msgstr ""
|
||||
"fantasy commands on a channel when prefixed\n"
|
||||
"with one of the following fantasy characters: %s\n"
|
||||
" \n"
|
||||
"Note that users wanting to use fantaisist\n"
|
||||
"commands MUST have enough access for both\n"
|
||||
"the FANTASIA and the command they are executing."
|
||||
"Note that users wanting to use fantasy commands\n"
|
||||
"MUST have enough access for both the FANTASY\n"
|
||||
"privilege and the command they are executing."
|
||||
|
||||
msgid ""
|
||||
" \n"
|
||||
@@ -3669,8 +3669,8 @@ msgstr "Email for %s is invalid."
|
||||
msgid "Email matched: %s (%s) to %s."
|
||||
msgstr "Email matched: %s (%s) to %s."
|
||||
|
||||
msgid "Enable fantaisist commands"
|
||||
msgstr "Enable fantaisist commands"
|
||||
msgid "Enable fantasy commands"
|
||||
msgstr "Enable fantasy commands"
|
||||
|
||||
msgid "Enable greet messages"
|
||||
msgstr "Enable greet messages"
|
||||
|
||||
@@ -252,7 +252,7 @@ static Anope::string GetLevelName(int level)
|
||||
case 15:
|
||||
return "NOKICK";
|
||||
case 16:
|
||||
return "FANTASIA";
|
||||
return "FANTASY";
|
||||
case 17:
|
||||
return "SAY";
|
||||
case 18:
|
||||
|
||||
+7
-7
@@ -17,7 +17,7 @@ class CommandBSSetFantasy final
|
||||
public:
|
||||
CommandBSSetFantasy(Module *creator, const Anope::string &sname = "botserv/set/fantasy") : Command(creator, sname, 2, 2)
|
||||
{
|
||||
this->SetDesc(_("Enable fantaisist commands"));
|
||||
this->SetDesc(_("Enable fantasy commands"));
|
||||
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037}"));
|
||||
}
|
||||
|
||||
@@ -73,9 +73,9 @@ public:
|
||||
"fantasy commands on a channel when prefixed\n"
|
||||
"with one of the following fantasy characters: \002%s\002\n"
|
||||
" \n"
|
||||
"Note that users wanting to use fantaisist\n"
|
||||
"commands MUST have enough access for both\n"
|
||||
"the FANTASIA and the command they are executing."),
|
||||
"Note that users wanting to use fantasy commands\n"
|
||||
"MUST have enough access for both the FANTASY\n"
|
||||
"privilege and the command they are executing."),
|
||||
Config->GetModule(this->owner)->Get<const Anope::string>("fantasycharacter", "!").c_str());
|
||||
return true;
|
||||
}
|
||||
@@ -186,10 +186,10 @@ public:
|
||||
source.permission = info.permission;
|
||||
|
||||
AccessGroup ag = c->ci->AccessFor(u);
|
||||
bool has_fantasia = ag.HasPriv("FANTASIA") || source.HasPriv("botserv/fantasy");
|
||||
bool has_fantasy = ag.HasPriv("FANTASY") || source.HasPriv("botserv/fantasy");
|
||||
|
||||
EventReturn MOD_RESULT;
|
||||
if (has_fantasia)
|
||||
if (has_fantasy)
|
||||
{
|
||||
FOREACH_RESULT(OnBotFantasy, MOD_RESULT, (source, cmd, c->ci, params));
|
||||
}
|
||||
@@ -198,7 +198,7 @@ public:
|
||||
FOREACH_RESULT(OnBotNoFantasyAccess, MOD_RESULT, (source, cmd, c->ci, params));
|
||||
}
|
||||
|
||||
if (MOD_RESULT == EVENT_STOP || !has_fantasia)
|
||||
if (MOD_RESULT == EVENT_STOP || !has_fantasy)
|
||||
return;
|
||||
|
||||
if (MOD_RESULT != EVENT_ALLOW && !info.permission.empty() && !source.HasCommand(info.permission))
|
||||
|
||||
@@ -239,6 +239,10 @@ Serializable *ChannelInfo::Unserialize(Serializable *obj, Serialize::Data &data)
|
||||
spacesepstream(slevels).GetTokens(v);
|
||||
for (unsigned i = 0; i + 1 < v.size(); i += 2)
|
||||
{
|
||||
// Begin 2.0 database compatibility.
|
||||
if (v[i] == "FANTASIA")
|
||||
v[i] = "FANTASY";
|
||||
// End 2.0 database compatibility.
|
||||
if (auto level = Anope::TryConvert<int16_t>(v[i + 1]))
|
||||
ci->levels[v[i]] = level.value();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user