This commit is contained in:
Dragon Fire
2024-05-03 10:28:55 -04:00
parent e92f705824
commit 6dbd29cb03
158 changed files with 158 additions and 159 deletions
+1 -1
View File
@@ -42,6 +42,6 @@ module.exports = class AvatarFusionCommand extends Command {
ctx.globalAlpha = 0.5;
ctx.drawImage(baseAvatar, 0, 0);
ctx.drawImage(overlayAvatar, 0, 0, baseAvatar.width, baseAvatar.height);
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'avatar-fusion.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'avatar-fusion.png' }] });
}
};
+1 -1
View File
@@ -154,6 +154,6 @@ module.exports = class HatCommand extends Command {
ctx.drawImage(avatar, 0, 0);
ctx.drawImage(base, 0, 0, avatar.width, avatar.height);
const comment = user.id === this.client.user.id ? hat.commentMe : hat.comment.replace(/{{user}}/g, user.tag);
return msg.say(comment, { files: [{ attachment: canvas.toBuffer(), name: `${type}-hat.png` }] });
return msg.say(comment, { files: [{ attachment: canvas.toBuffer('image/png'), name: `${type}-hat.png` }] });
}
};
+1 -1
View File
@@ -47,6 +47,6 @@ module.exports = class HeLivesInYouCommand extends Command {
ctx.rotate(-24 * (Math.PI / 180));
drawImageWithTint(ctx, avatar, '#00115d', 75, 160, 130, 150);
ctx.rotate(24 * (Math.PI / 180));
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'he-lives-in-you.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'he-lives-in-you.png' }] });
}
};
+1 -1
View File
@@ -45,6 +45,6 @@ module.exports = class HeartsCommand extends Command {
const ctx = canvas.getContext('2d');
drawImageWithTint(ctx, avatar, 'deeppink', 0, 0, avatar.width, avatar.height);
ctx.drawImage(base, 0, 0, avatar.width, avatar.height);
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'hearts.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'hearts.png' }] });
}
};
+1 -1
View File
@@ -45,6 +45,6 @@ module.exports = class IHaveThePowerCommand extends Command {
ctx.rotate(18.3 * (Math.PI / 180));
ctx.drawImage(avatar, 332, -125, 175, 175);
ctx.rotate(-18.3 * (Math.PI / 180));
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'i-have-the-power.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'i-have-the-power.png' }] });
}
};
+1 -1
View File
@@ -67,6 +67,6 @@ module.exports = class RipCommand extends Command {
if (cause) ctx.fillText(cause, 438, 910, 500);
ctx.font = this.client.fonts.get('CoffinStone.otf').toCanvasString(37);
ctx.fillText('In Loving Memory of', 438, 292);
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'rip.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'rip.png' }] });
}
};
+1 -1
View File
@@ -58,6 +58,6 @@ module.exports = class SteamNowPlayingCommand extends Command {
ctx.font = this.client.fonts.get('Noto-Regular.ttf').toCanvasString(14);
ctx.fillText(user.username, 80, 34);
ctx.fillText(shortenText(ctx, game, 200), 80, 70);
return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'steam-now-playing.png' }] });
return msg.say({ files: [{ attachment: canvas.toBuffer('image/png'), name: 'steam-now-playing.png' }] });
}
};