Special case if ship users are the same

This commit is contained in:
Daniel Odendahl Jr
2018-04-22 01:32:27 +00:00
parent bf23390e7c
commit 34d8713c27
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -26,6 +26,7 @@ module.exports = class ShipCommand extends Command {
}
run(msg, { first, second }) {
if (first.id === second.id) return msg.reply('Shipping someone with themselves would be pretty weird.');
const random = new Random(Random.engines.mt19937().seed(Math.abs(first.id - second.id)));
return msg.say(`I'd give ${first.username} and ${second.username} a ${random.integer(0, 100)}%!`);
}
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiao",
"version": "73.1.0",
"version": "73.1.1",
"description": "Your personal server companion.",
"main": "Xiao.js",
"scripts": {