mirror of
https://github.com/pieartsy/PluralFlux.git
synced 2026-04-17 01:55:27 +10:00
added some cases to memberHelper for documentation and tweaked wording
This commit is contained in:
8
enums.js
8
enums.js
@@ -13,10 +13,10 @@ helperEnums.err = {
|
|||||||
|
|
||||||
helperEnums.help = {
|
helperEnums.help = {
|
||||||
MEMBER: "You can shorten this command to `pf;m`. The available subcommands for `pf;member` are `add`, `remove`, `displayname`, and `proxy`. Add ` --help` to the end of a subcommand to find out more about it, or just send it without arguments.",
|
MEMBER: "You can shorten this command to `pf;m`. The available subcommands for `pf;member` are `add`, `remove`, `displayname`, and `proxy`. Add ` --help` to the end of a subcommand to find out more about it, or just send it without arguments.",
|
||||||
ADD: "Creates a new member to proxy with: `pf;member jane`. The member name should ideally be short so you can write other commands with it. \nYou can optionally add a display name after the member name: `pf;member new jane \"Jane Doe | ze/hir\"`. If it has spaces, put it in **double quotes**. The length limit is 32 characters.",
|
ADD: "Creates a new member to proxy with, for example: `pf;member jane`. The member name should ideally be short so you can write other commands with it. \nYou can optionally add a display name after the member name, for example: `pf;member new jane \"Jane Doe | ze/hir\"`. If it has spaces, put it in **double quotes**. The length limit is 32 characters.",
|
||||||
REMOVE: "Removes a member based on their name. `pf;member remove jane`.",
|
REMOVE: "Removes a member based on their name, for example: `pf;member remove jane`.",
|
||||||
DISPLAYNAME: "Updates the display name for a specific member based on their name. `pf;member jane \"Jane Doe | ze/hir\"`.This can be up to 32 characters long. If it has spaces, put it in quotes.",
|
DISPLAYNAME: "Updates the display name for a specific member based on their name, for example: `pf;member jane \"Jane Doe | ze/hir\"`.This can be up to 32 characters long. If it has spaces, put it in quotes.",
|
||||||
PROXY: "Updates the proxy tag for a specific member based on their name. `pf;member jane proxy Jane:`. This is put at **the start** of a message to allow it to be proxied. Proxies that wrap around text or go at the end are **not** currently supported."
|
PROXY: "Updates the proxy tag for a specific member based on their name, for example: `pf;member jane proxy Jane:` or `pf;member amal proxy A=:`. This is put at **the start** of a message to allow it to be proxied. Proxies that wrap around text or go at the end are **not** currently supported."
|
||||||
}
|
}
|
||||||
|
|
||||||
export const enums = helperEnums;
|
export const enums = helperEnums;
|
||||||
@@ -12,9 +12,6 @@ const mh = {};
|
|||||||
*/
|
*/
|
||||||
mh.parseMemberCommand = async function(authorId, args){
|
mh.parseMemberCommand = async function(authorId, args){
|
||||||
console.log(authorId, args);
|
console.log(authorId, args);
|
||||||
if (!args) {
|
|
||||||
return enums.help.MEMBER;
|
|
||||||
}
|
|
||||||
switch(args[0]) {
|
switch(args[0]) {
|
||||||
case '--help':
|
case '--help':
|
||||||
return enums.help.MEMBER;
|
return enums.help.MEMBER;
|
||||||
@@ -22,6 +19,12 @@ mh.parseMemberCommand = async function(authorId, args){
|
|||||||
return addNewMember(authorId, args);
|
return addNewMember(authorId, args);
|
||||||
case 'remove':
|
case 'remove':
|
||||||
return removeMember(authorId, args);
|
return removeMember(authorId, args);
|
||||||
|
case 'displayname':
|
||||||
|
return enums.help.DISPLAYNAME;
|
||||||
|
case 'proxy':
|
||||||
|
return enums.help.PROXY;
|
||||||
|
case '':
|
||||||
|
return enums.help.MEMBER;
|
||||||
}
|
}
|
||||||
switch(args[1]) {
|
switch(args[1]) {
|
||||||
case '--help':
|
case '--help':
|
||||||
|
|||||||
Reference in New Issue
Block a user