Skip to content

Commit

Permalink
feat: support command
Browse files Browse the repository at this point in the history
  • Loading branch information
cfanoulis committed Nov 7, 2019
1 parent adc6d84 commit 4bf59bc
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
28 changes: 28 additions & 0 deletions src/commands/System/support.ts
@@ -0,0 +1,28 @@
import { SkyraCommand } from '../../lib/structures/SkyraCommand';
import { CommandStore, KlasaMessage } from 'klasa';
import { MessageEmbed } from 'discord.js';
import { BrandingColors } from '../../lib/util/constants';

export default class extends SkyraCommand {

public constructor(store: CommandStore, file: string[], directory: string) {
super(store, file, directory, {
aliases: ['supportserver', 'server'],
description: language => language.tget('COMMAND_SUPPORT_DESCRIPTION'),
extendedHelp: language => language.tget('COMMAND_SUPPORT_EXTENDED_HELP'),
guarded: true,
permissionLevel: 0
});

}

public run(message: KlasaMessage) {
const embed = new MessageEmbed()
// TODO: LANGUAGE SUPPORT YOU IDIOT
.setTitle(message.language.tget('COMMAND_SUPPORT_EMBED_TITLE', message.author.username))
.setDescription(message.language.tget('COMMAND_SUPPORT_EMBED_DESCRIPTION'))
.setColor(BrandingColors.Primary);
return message.send(embed);
}

}
4 changes: 4 additions & 0 deletions src/languages/en-US.ts
Expand Up @@ -1970,6 +1970,10 @@ export default class extends Language {
COMMAND_HELP_TITLE: (name, description) => `📃 | ***Help Message*** | __**${name}**__\n${description}\n`,
COMMAND_HELP_USAGE: usage => `📝 | ***Command Usage***\n\`${usage}\`\n`,
COMMAND_HELP_EXTENDED: extendedHelp => `🔍 | ***Extended Help***\n${extendedHelp}`,
COMMAND_SUPPORT_DESCRIPTION: `Show support instructions`,
COMMAND_SUPPORT_EXTENDED_HELP: `Literally gives you a link to our support server. What did you really expect this to do :thinking:`,
COMMAND_SUPPORT_EMBED_TITLE: username => `Looking for help, ${username}?`,
COMMAND_SUPPORT_EMBED_DESCRIPTION: `Then you should probably join [Skyra\'s lounge](https://discord.gg/92mEkYz)! There, you can receive support by the developers and other members of the community!`,

/**
* ##############
Expand Down
4 changes: 4 additions & 0 deletions src/lib/types/Languages.d.ts
Expand Up @@ -169,6 +169,10 @@ export interface LanguageKeys {
COMMAND_SKIP_VOTES_VOTED: string;
COMMAND_SKIP_VOTES_TOTAL: (amount: number, needed: number) => string;
COMMAND_SKIP_SUCCESS: (title: string) => string;
COMMAND_SUPPORT_DESCRIPTION: string;
COMMAND_SUPPORT_EXTENDED_HELP: string;
COMMAND_SUPPORT_EMBED_TITLE: (username: string) => string;
COMMAND_SUPPORT_EMBED_DESCRIPTION: string;
COMMAND_TIME_DESCRIPTION: string;
COMMAND_TIME_QUEUE_EMPTY: string;
COMMAND_TIME_STREAM: string;
Expand Down

0 comments on commit 4bf59bc

Please sign in to comment.