mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-27 06:37:32 +02:00
Wrap fen in codeblocks
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
const Command = require('../../structures/Command');
|
const Command = require('../../structures/Command');
|
||||||
const { escapeMarkdown } = require('discord.js');
|
|
||||||
const jsChess = require('js-chess-engine');
|
const jsChess = require('js-chess-engine');
|
||||||
const { createCanvas, loadImage } = require('canvas');
|
const { createCanvas, loadImage } = require('canvas');
|
||||||
const moment = require('moment');
|
const moment = require('moment');
|
||||||
@@ -127,7 +126,7 @@ module.exports = class ChessCommand extends Command {
|
|||||||
|
|
||||||
_You are ${gameState.check ? '**in check!**' : 'not in check.'}_
|
_You are ${gameState.check ? '**in check!**' : 'not in check.'}_
|
||||||
**Time Remaining: ${displayTime}** (Max 10min per turn)
|
**Time Remaining: ${displayTime}** (Max 10min per turn)
|
||||||
**FEN:** ${escapeMarkdown(game.exportFEN())}
|
**FEN:** \`${game.exportFEN()}\`
|
||||||
`, { files: [{ attachment: this.displayBoard(gameState, prevPieces), name: 'chess.png' }] });
|
`, { files: [{ attachment: this.displayBoard(gameState, prevPieces), name: 'chess.png' }] });
|
||||||
prevPieces = Object.assign({}, game.exportJson().pieces);
|
prevPieces = Object.assign({}, game.exportJson().pieces);
|
||||||
const moves = game.moves();
|
const moves = game.moves();
|
||||||
|
|||||||
Reference in New Issue
Block a user