Facebook
From Alestero , 2 Months ago, written in JavaScript.
Embed
Download Paste or View Raw
Hits: 52
  1. const Discord = require('discord.js');
  2. const db = require('quick.db');
  3.  
  4. exports.run = async (client, message, params, args) => {
  5.   if (!message.member.hasPermission('ADMINISTRATOR')) return message.channel.send(' <a:Ship_32:706654929904992318>  Ho┼čgeldin kanal─▒ ayarlamak i├žin `Y├Ânetici` yetkisine sahip olman gerek.')
  6.   let hgkanali = message.mentions.channels.first();
  7.   if (!hgkanali) return message.channel.send(' <a:Ship_32:706654929904992318>  Ho┼čgeldin kanal─▒ ayarlamak i├žin bir kanal etiketlemeniz gerekli. `?giri┼č-├ž─▒k─▒┼č-ayarla #kanal`')
  8.     db.set(`gcc_${message.guild.id}`, message.mentions.channels.first().id)
  9.   let i = await db.fetch(`gcc_${message.guild.id}`)
  10.   message.channel.send(` <a:Ship_22:706655299997663262>  ${process.env.basarili} Ho┼čgeldin kanal─▒, <#${i}> olarak ayarland─▒.`)    
  11.        
  12. };
  13.  
  14. exports.conf = {
  15.  enabled: true,
  16.  guildOnly: false,
  17.  aliases: [],
  18.  permLevel: 0
  19. };
  20.  
  21. exports.help = {
  22.  name: 'giri┼č-├ž─▒k─▒┼č-ayarla',
  23.  description: 'neblm',
  24.  usage: 'giri┼č-├ž─▒k─▒┼č-ayarla'
  25. };
  26.                        
  27.                        
  28.                        
  29.                        //////////////
  30.                        EVENTLODER'E
  31. client.on('guildMemberAdd', reqEvent('giri┼č'));  //Resimli  HG-BB HG
  32.  
  33.  client.on('guildMemberRemove', reqEvent('├ž─▒k─▒┼č')); // Resimli HG-BB BB
  34.  
  35. ///////////////////////////////////////////////////////////////////////////////////
  36.  
  37.  
  38.  
  39. events/giri┼č
  40.  
  41.  
  42. const Discord = require("discord.js")
  43. const db = require("quick.db");
  44. const Canvas = require('canvas')
  45.    , Image = Canvas.Image
  46.    , Font = Canvas.Font
  47.    , path = require('path');
  48. const snekfetch = require('snekfetch');
  49. const request = require('node-superfetch');
  50.  
  51. module.exports = async member => {
  52.    var randomMsg = [
  53.                    " <:Ship_54:709900576099532920> Partiye Ho┼čgeldin",      
  54.                    ];
  55.    var randomMsg_integer = randomMsg[Math.floor((Math.random() * randomMsg.length))]
  56.  
  57.  let msj = await db.fetch(`girisM_${member.guild.id}`)
  58.  if (!msj) msj = `{uye}, ${randomMsg_integer}`
  59.  let memberChannel = await db.fetch(`gcc_${member.guild.id}`)
  60.  
  61.  const canvas = Canvas.createCanvas(800, 500);
  62.  const ctx = canvas.getContext('2d');
  63.  
  64.  const background = await Canvas.loadImage('RES─░M LinQ');
  65.  ctx.drawImage(background, 6, 6, canvas.width, canvas.height);
  66.  
  67.  ctx.strokeStyle = '#74037b';
  68.  ctx.strokeRect(0, 0, canvas.width, canvas.height);
  69.  
  70.  ctx.fillStyle = `#D3D3D3`;
  71.  ctx.font = `25px "Warsaw`;
  72.  ctx.textAlign = "center";
  73.  ctx.fillText(`${member.user.username.toUpperCase()}`, 410, 430);
  74.  
  75.  let avatarURL = member.user.avatarURL || member.user.defaultAvatarURL
  76.  const { body } = await request.get(avatarURL);
  77.  const avatar = await Canvas.loadImage(body);
  78.  
  79.  ctx.beginPath();
  80.  ctx.lineWidth = 15;
  81.  ctx.fill()
  82.  ctx.lineWidth = 4;
  83.         ctx.arc(408.6, 259.7, 103.3, 0, Math.PI * 2, false);
  84.  ctx.clip();
  85.  ctx.drawImage(avatar,  308.6, 159.7, 200, 200);
  86.  
  87.  const attachment = new Discord.Attachment(canvas.toBuffer(), 'Shard-HG.png');
  88.  member.guild.channels.get(memberChannel).send(attachment)
  89.  member.guild.channels.get(memberChannel).send(msj.replace('{uye}', member).replace('{sunucu}', member.guild.name))
  90.  if (member.user.bot) return member.guild.channels.get(memberChannel).send(`? Bu Bot Oldugu Tespit Edildi, ${member.user.tag}`)
  91.  
  92. }
  93.  
  94.  
  95.  events/├ž─▒k─▒┼č
  96.    
  97.    
  98.  
  99.  
  100.  
  101.  
  102.  
  103. const Discord = require("discord.js")
  104. const db = require("quick.db");
  105. const Canvas = require('canvas')
  106.    , Image = Canvas.Image
  107.    , Font = Canvas.Font
  108.    , path = require('path');
  109. const snekfetch = require('snekfetch');
  110. const request = require('node-superfetch');
  111.  
  112. module.exports = async member => {  
  113.   var randomMsg = [
  114.                    " <:Ship_53:709900576221298718> Paryiden Ayr─▒ld─▒ Yine Bekleriz "
  115.                    ];
  116.    var randomMsg_integer = randomMsg[Math.floor((Math.random() * randomMsg.length))]
  117.  
  118.  let paket = await db.fetch(`pakets_${member.id}`)
  119.  let memberChannel = await db.fetch(`gcc_${member.guild.id}`)
  120.  let msj = await db.fetch(`cikisM_${member.guild.id}`)
  121.  if (!msj) msj = `{uye}, ${randomMsg_integer}`
  122.  
  123.  
  124.  const canvas = Canvas.createCanvas(800, 500);
  125.         const ctx = canvas.getContext('2d');
  126.  
  127.  const background = await Canvas.loadImage('Resim Linq');
  128.  ctx.drawImage(background,  6, 6, canvas.width, canvas.height);
  129.  
  130.  ctx.strokeStyle = '#74037b';
  131.         ctx.strokeRect(0, 0, canvas.width, canvas.height);
  132.  
  133.  ctx.fillStyle = `#D3D3D3`;
  134.         ctx.font = `25px "Warsaw"`;
  135.         ctx.textAlign = "center";
  136.         ctx.fillText(`${member.user.username.toUpperCase()}`, 410, 430);
  137.  
  138.  let avatarURL = member.user.avatarURL || member.user.defaultAvatarURL
  139.  const { body } = await request.get(avatarURL);
  140.         const avatar = await Canvas.loadImage(body);
  141.  
  142.  ctx.beginPath();
  143.         ctx.lineWidth = 4;
  144.  ctx.fill()
  145.         ctx.lineWidth = 4;
  146.         ctx.arc(408.6, 259.7, 103.3, 0, Math.PI * 2, false);
  147.         ctx.clip();
  148.         ctx.drawImage(avatar, 308.6, 159.7, 200, 200);
  149.  
  150.  const attachment = new Discord.Attachment(canvas.toBuffer(), 'Shard-BB.png');
  151.  member.guild.channels.get(memberChannel).send(attachment)
  152.  member.guild.channels.get(memberChannel).send(msj.replace('{uye}', member).replace('{sunucu}', member.guild.name));
  153.  if (member.user.bot) return member.guild.channels.get(memberChannel).send(`? Bu bir bot, ${member.user.tag}`)
  154.  
  155.  
  156. }
  157.  
  158.  
  159.