Improve bob-ross positioning

This commit is contained in:
Daniel Odendahl Jr
2018-10-07 19:47:21 +00:00
parent cd0371826f
commit 70a1b8905c
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -28,7 +28,7 @@ module.exports = class BobRossCommand extends Command {
}
async run(msg, { user }) {
const avatarURL = user.displayAvatarURL({ format: 'png', size: 256 });
const avatarURL = user.displayAvatarURL({ format: 'png', size: 512 });
try {
const base = await loadImage(path.join(__dirname, '..', '..', 'assets', 'images', 'bob-ross.png'));
const { body } = await request.get(avatarURL);
@@ -38,7 +38,7 @@ module.exports = class BobRossCommand extends Command {
ctx.fillStyle = 'white';
ctx.fillRect(0, 0, base.width, base.height);
ctx.rotate(3 * (Math.PI / 180));
ctx.drawImage(avatar, 69, 102, 256, 256);
ctx.drawImage(avatar, 30, 19, 430, 430);
ctx.rotate(-3 * (Math.PI / 180));
ctx.drawImage(base, 0, 0);
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'bob-ross.png' }] });
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiao",
"version": "92.4.1",
"version": "92.4.2",
"description": "Your personal server companion.",
"main": "Xiao.js",
"scripts": {