mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-04 15:56:52 +02:00
Fix emoji emoji revolution
This commit is contained in:
@@ -2,6 +2,7 @@ const Command = require('../../structures/Command');
|
||||
const { stripIndents } = require('common-tags');
|
||||
const { verify } = require('../../util/Util');
|
||||
const emojis = ['⬆', '↗', '➡', '↘', '⬇', '↙', '⬅', '↖'];
|
||||
const emojisNew = ['⬆️', '↗️', '➡️', '↘️', '⬇️', '↙️', '⬅️', '↖️'];
|
||||
|
||||
module.exports = class EmojiEmojiRevolutionCommand extends Command {
|
||||
constructor(client) {
|
||||
@@ -40,9 +41,10 @@ module.exports = class EmojiEmojiRevolutionCommand extends Command {
|
||||
let oPts = 0;
|
||||
while (turn < 10) {
|
||||
++turn;
|
||||
const emoji = emojis[Math.floor(Math.random() * emojis.length)];
|
||||
const num = Math.floor(Math.random() * emojis.length);
|
||||
const emoji = [emojis[num], emojisNew[num]];
|
||||
await msg.say(emoji);
|
||||
const filter = res => [msg.author.id, opponent.id].includes(res.author.id) && res.content === emoji;
|
||||
const filter = res => [msg.author.id, opponent.id].includes(res.author.id) && emoji.includes(res.content);
|
||||
const win = await msg.channel.awaitMessages(filter, {
|
||||
max: 1,
|
||||
time: 30000
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "xiao",
|
||||
"version": "109.2.0",
|
||||
"version": "109.2.1",
|
||||
"description": "Your personal server companion.",
|
||||
"main": "Xiao.js",
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user