diff options
author | destruc7i0n <destruc7i0n@users.noreply.github.com> | 2021-12-31 13:07:22 -0500 |
---|---|---|
committer | destruc7i0n <destruc7i0n@users.noreply.github.com> | 2021-12-31 13:07:22 -0500 |
commit | e489d05f1691c6d15dfde2138cc55e40265fe6f1 (patch) | |
tree | b9f4d0c40eee600de557158742806d0cbd7e7c2f /src/Shulker.ts | |
parent | fallback to bot message if webhook fails (diff) | |
parent | Missed an old 1.12 death message in the regex (diff) | |
download | shulker-e489d05f1691c6d15dfde2138cc55e40265fe6f1.tar.gz shulker-e489d05f1691c6d15dfde2138cc55e40265fe6f1.zip |
Merge branch 'death-message-regex' of https://github.com/MageLuingil/shulker into 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 { |