diff --git a/commands/misc/tdoss.js b/commands/misc/tdoss.js index 95b38da..b123ead 100644 --- a/commands/misc/tdoss.js +++ b/commands/misc/tdoss.js @@ -11,6 +11,7 @@ module.exports = { async execute({ message, args }) { let tdossDir = path.resolve(process.cwd(), 'data', 'tdoss'); + const tdossTemplate = path.resolve(process.cwd(), 'resources', 'tdoss_template.png'); const directory = path.resolve(tdossDir, Math.floor(new Date).toString()) fs.mkdirSync(directory, {recursive: true}) @@ -59,7 +60,7 @@ module.exports = { } - const command = `magick ${tdossDir}/tdoss_template.png \\( ${directory}/input.png -resize 800x800^ -gravity center -extent 1000x1000 \\) -compose dst-over -composite ${directory}/tdoss_result.png`; + const command = `magick ${tdossDir}/tdoss_template.png \\( ${directory}/input.png -resize 800x800^ -gravity center -extent 1000x1000 \\) -compose dst-over -composite ${tdossTemplate}`; if (this.executeCommand(command).error === true) { message.channel.send("Something went wrong during image manipulation.\nTry again and if it keeps happening, contact the owner of the bot.") fs.rmSync(`${directory}`, {recursive: true}) diff --git a/resources/tdoss_template.png b/resources/tdoss_template.png new file mode 100644 index 0000000..a2d7f4e Binary files /dev/null and b/resources/tdoss_template.png differ