diff options
author | destruc7i0n <destruc7i0n@users.noreply.github.com> | 2021-12-31 13:08:00 -0500 |
---|---|---|
committer | destruc7i0n <destruc7i0n@users.noreply.github.com> | 2021-12-31 13:08:00 -0500 |
commit | 7987f65b4b9625060e78ec4398ec16dd26e48bfa (patch) | |
tree | b9f4d0c40eee600de557158742806d0cbd7e7c2f /src/Shulker.ts | |
parent | fallback to bot message if webhook fails (diff) | |
parent | Merge branch 'death-message-regex' of https://github.com/MageLuingil/shulker ... (diff) | |
download | shulker-7987f65b4b9625060e78ec4398ec16dd26e48bfa.tar.gz shulker-7987f65b4b9625060e78ec4398ec16dd26e48bfa.zip |
Merge branch 'MageLuingil-death-message-regex'
Diffstat (limited to '')
-rw-r--r-- | src/Shulker.ts | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/Shulker.ts b/src/Shulker.ts index 220cd03..517d1e2 100644 --- a/src/Shulker.ts +++ b/src/Shulker.ts @@ -10,6 +10,11 @@ class Shulker { discordClient: DiscordClient handler: Handler + readonly deprecatedConfigs: string[] = ['DEATH_KEY_WORDS']; + + constructor() { + } + loadConfig () { const configFile = process.argv.length > 2 ? process.argv[2] : './config.json' if (!fs.existsSync(configFile)) { @@ -25,6 +30,12 @@ class Shulker { return false } + for (let option of this.deprecatedConfigs) { + if (this.config.hasOwnProperty(option)) { + console.log('[WARN] Using deprecated config option ' + option + '. Check README.md for current options.') + } + } + if (this.config.USE_WEBHOOKS) { console.log('[INFO] Using Discord WebHooks to send messages') } else { |