Dosen't allow gif anymore

This commit is contained in:
loicbersier 2018-10-16 11:55:57 +02:00
parent a3c97834fb
commit 865c141b5b
7 changed files with 24 additions and 10 deletions

View file

@ -23,8 +23,10 @@ module.exports = class fetishCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(528, 559)
const ctx = canvas.getContext('2d')

View file

@ -23,8 +23,10 @@ module.exports = class godCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(310, 400)
const ctx = canvas.getContext('2d')

View file

@ -23,9 +23,11 @@ module.exports = class humanCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(578, 400)
const ctx = canvas.getContext('2d')
const background = await loadImage('https://image.noelshack.com/fichiers/2018/42/1/1539594726-untitled.png').catch(error => {

View file

@ -31,9 +31,11 @@ module.exports = class idubbbzCommand extends Command {
let Attachment = (message.attachments).array();
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else
image = Attachment[0].url
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
const canvas = createCanvas(1281, 627)
const applyText = (canvas, text) => {

View file

@ -32,8 +32,10 @@ module.exports = class idubbbzpaintCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(1024, 544)
const applyText = (canvas, text) => {

View file

@ -23,8 +23,10 @@ module.exports = class likeCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(386, 399)
const ctx = canvas.getContext('2d')

View file

@ -23,8 +23,10 @@ module.exports = class uglyCommand extends Command {
let image = null
if (!Attachment[0])
image = message.author.displayAvatarURL
else if(Attachment[0] && Attachment[0].url.endsWith('gif'))
return message.say('Gif dosent work, sorry')
else
image = Attachment[0].url
image = Attachment[0].url
const canvas = createCanvas(323, 400)
const ctx = canvas.getContext('2d')