diff --git a/README.md b/README.md index 7b6f5600..d8df7625 100644 --- a/README.md +++ b/README.md @@ -262,7 +262,7 @@ in the appropriate channel's topic to use it. ## Commands -Total: 594 +Total: 593 ### Utility: diff --git a/commands/games-mp/typing-race.js b/commands/games-mp/typing-race.js index 1b0678ba..567ab422 100644 --- a/commands/games-mp/typing-race.js +++ b/commands/games-mp/typing-race.js @@ -59,8 +59,9 @@ module.exports = class TypingRaceCommand extends Command { } this.client.games.delete(msg.channel.id); if (!winner.size) return msg.say('Oh... No one won.'); + const wpm = (sentence.length / 5) / ((newScore / 1000) / 60); return msg.say(stripIndents` - The winner is ${winner.first().author}! (Took ${newScore / 1000} seconds) + The winner is ${winner.first().author}! (Took ${newScore / 1000} seconds, ${wpm} WPM) ${scoreBeat ? `**New High Score!** Old:` : `High Score:`} ${highScore / 1000} (Held by ${user}) `); } catch (err) { diff --git a/commands/games-sp/typing-test.js b/commands/games-sp/typing-test.js index 93eaa85d..860da275 100644 --- a/commands/games-sp/typing-test.js +++ b/commands/games-sp/typing-test.js @@ -39,8 +39,9 @@ module.exports = class TypingTestCommand extends Command { } if (!msgs.size) return msg.reply('Sorry! You lose!'); if (msgs.first().content.toLowerCase() !== sentence) return msg.reply('Sorry! You made a typo, so you lose!'); + const wpm = (sentence.length / 5) / ((newScore / 1000) / 60); return msg.reply(stripIndents` - Nice job! 10/10! You deserve some cake! (Took ${newScore / 1000} seconds) + Nice job! 10/10! You deserve some cake! (Took ${newScore / 1000} seconds, ${wpm} WPM) ${scoreBeat ? `**New High Score!** Old:` : `High Score:`} ${highScore / 1000} (Held by ${user}) `); } diff --git a/package.json b/package.json index 54b4c084..713a5be7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiao", - "version": "129.0.0", + "version": "129.0.1", "description": "Your personal server companion.", "main": "Xiao.js", "scripts": {