summaryrefslogtreecommitdiff
path: root/fix/utility
diff options
context:
space:
mode:
author8cy <[email protected]>2020-07-23 23:24:17 -0700
committer8cy <[email protected]>2020-07-23 23:24:17 -0700
commitbb511abc03bb66848947e37a999502b813c77269 (patch)
tree612c010fc8317e1cdf11471a18aad0270819d33e /fix/utility
parentfix: if clear amount equal or over 100, round down to 99 (diff)
downloaddep-core-bb511abc03bb66848947e37a999502b813c77269.tar.xz
dep-core-bb511abc03bb66848947e37a999502b813c77269.zip
goodbye old uwufier :cry:
Diffstat (limited to 'fix/utility')
-rw-r--r--fix/utility/math.ts56
1 files changed, 0 insertions, 56 deletions
diff --git a/fix/utility/math.ts b/fix/utility/math.ts
deleted file mode 100644
index a55edf1..0000000
--- a/fix/utility/math.ts
+++ /dev/null
@@ -1,56 +0,0 @@
-// TODO: get this working someday
-import { Command, CommandoMessage } from 'discord.js-commando';
-import emoji from 'emoji-random';
-
-module.exports = class MathUtility extends Command {
- constructor(client) {
- super(client, {
- name: 'math',
- group: 'utility',
- memberName: 'math',
- description: 'Allows you to do simple math operations.',
- args: [
- {
- key: 'mVal1',
- prompt: 'First number?',
- type: 'integer'
- },
- {
- key: 'mOp',
- prompt: 'What operation would you like to use?',
- type: 'string'
- },
- {
- key: 'mVal2',
- prompt: 'Second number?',
- type: 'integer'
- }
- ],
- examples: [
- 'uwu!math 5 + 2'
- ]
- });
- }
- async run(msg: CommandoMessage, { mVal1, mOp, mVal2 }) {
- if (!mVal1 || !mOp || !mVal2) {
- msg.reply('You are missing a critical part of the operation, please try again.')
- } else {
- var mSol
- switch (mOp) {
- case mOp = '+':
- if (mVal1 < mVal2) mSol = mVal1 + mVal1;
- break
- case mOp = '-':
- mSol = mVal1 - mVal1;
- break
- case mOp = '/':
- mSol = mVal1 / mVal1;
- break
- case mOp = '*' || 'x':
- mSol = mVal1 * mVal1;
- break
- }
- await msg.reply(`**${mVal1}** ${mOp} **${mVal2}** = **${mSol}**.`)
- }
- }
-}; \ No newline at end of file