Advertisement
n3k4a

SERVER CODE WITH IMGE | كود سيرفر بي الصور

Feb 13th, 2020
461
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.84 KB | None | 0 0
  1. /* اعاده نشر الكود بي حقوقك توكسك كودز فقط
  2.  
  3. اي احد يزرفه يستحمل الباند الي بيجيه في الدسكورد _:)*/
  4. const bbg =["https://i.pinimg.com/236x/22/75/5f/22755f39c8f4f712cfdb237a4b8f0e7a.jpg", //Toxic Codes
  5. "https://i.pinimg.com/564x/b6/d9/94/b6d994a07f9dd19a98b52994b5fcf7d7.jpg", //Toxic Codes
  6. "https://i.pinimg.com/236x/2d/7a/92/2d7a92241570589639f5922a5021a38e.jpg", //Toxic Codes
  7. "https://i.pinimg.com/236x/2a/f7/f3/2af7f307ccfda22028e261657f07ca7b.jpg", //Toxic Codes
  8. "https://i.pinimg.com/236x/1e/08/fc/1e08fca2fc4df9f5cbca156d61b6ecd3.jpg", //Toxic Codes
  9. "https://i.pinimg.com/236x/f5/f8/38/f5f8380ef692c55e7b97cf0f64d07556.jpg", //Toxic Codes
  10. ]; //Toxic Codes
  11. client.on("message",async msg => { //Toxic Codes
  12. if(msg.content.startsWith(prefix + "server")){ //Toxic Codes
  13. const Canvas = require("canvas"); //Toxic Codes
  14. let mentions = msg.mentions.members.first() //Toxic Codes
  15. if(!mentions) { //Toxic Codes
  16. let bbs = bbg[Math.floor(Math.random() * bbg.length)]
  17. let serverid = msg.guild.id //Toxic Codes
  18. let serverna = msg.guild.name //Toxic Codes
  19. let owner = msg.guild.owner //Toxic Codes
  20. let ownerna = owner.user.username //Toxic Codes
  21. let ownerta = owner.user.discriminator//Toxic Codes
  22. let channels = msg.guild.channels.size //Toxic Codes
  23. let voice = msg.guild.channels.filter(f => f.type === "voice").size //Toxic Codes
  24. let text = msg.guild.channels.filter(f => f.type === "text").size //Toxic Codes
  25. let createdo = moment(msg.guild.createdAt).format(`D/M/YYYY h:mm`) //Toxic Codes
  26. let createdf = moment(msg.guild.createdAt).locale("EN-eg").fromNow() //Toxic Codes
  27. let members = msg.guild.members.size //Toxic Codes
  28. let online = msg.guild.members.filter(c => c.presence.status !== "offline").size //Toxic Codes
  29. let region = msg.guild.region //Toxic Codes
  30. let verificationl = msg.guild.verificationLevel //Toxic Codes
  31. let roles = msg.guild.roles.size //Toxic Codes
  32. let by = msg.author.username //Toxic Codes
  33. let tserverid = "server id:" //Toxic Codes
  34. let townerna = "owner:" //Toxic Codes
  35. let tchannels = "channels:" //Toxic Codes
  36. let tvoice = "voice:" //Toxic Codes
  37. let ttext = "text:" //Toxic Codes
  38. let tcreatedo = "created at:" //Toxic Codes
  39. let tregion = "region:" //Toxic Codes
  40. let tverificationl = "verification level:" //Toxic Codes
  41. let troles = "roles" //Toxic Codes
  42. let tmembers = "members:" //Toxic Codes
  43. let tonline = "online:" //Toxic Codes
  44. let hm = "Requested by" //Toxic Codes
  45. let servericon = msg.guild.iconURL //Toxic Codes
  46. let canvas = Canvas.createCanvas(800 , 500) //Toxic Codes
  47. let ctx = canvas.getContext('2d'); //Toxic Codes
  48. const background = await Canvas.loadImage(`${bbs}`);//Toxic Codes
  49. const bg = await Canvas.loadImage("https://cdn.discordapp.com/attachments/637449457658494999/642490023954087946/hmmmm.PNG");
  50. const icon = await Canvas.loadImage(`${servericon}`); //Toxic Codes
  51. const avatar = await Canvas.loadImage(`${msg.author.avatarURL}`);
  52. ctx.drawImage(background, 0, 0, canvas.width, canvas.height); //Toxic Codes
  53. ctx.drawImage(bg, 0, 0, canvas.width, canvas.height); //Toxic Codes
  54. ctx.font = '25px Elephant';//Toxic Codes
  55. ctx.fontSize = '30px';//Toxic Codes
  56. ctx.textAlign = "center";//Toxic Codes
  57. ctx.fillStyle = "#007cff"; //Toxic Codes
  58. ctx.fillText(serverid, canvas.width / 2, canvas.height / 1.6); //Toxic Codes
  59. ctx.font = '30px Elephant';//Toxic Codes
  60. ctx.fillStyle = "#ffffff"; //Toxic Codes
  61. ctx.fillText(serverna, canvas.width / 2, canvas.height / 2); //Toxic Codes
  62. ctx.font = '25px Elephant';//Toxic Codes
  63. ctx.fillStyle = "#ffd304"; //Toxic Codes
  64. ctx.fillText(ownerna+"#"+ownerta, canvas.width / 2, canvas.height / 1.8); //Toxic Codes
  65. ctx.fillStyle = "#ffffff"; //Toxic Codes
  66. ctx.fillText(channels, canvas.width / 1.1, canvas.height / 6); //Toxic Codes
  67. ctx.fillText(voice, canvas.width / 1.1, canvas.height / 4.8); //Toxic Codes
  68. ctx.fillText(text, canvas.width / 1.1, canvas.height / 3.9); //Toxic Codes
  69. ctx.fillStyle = "#e9abab"; //Toxic Codes
  70. ctx.fillText(createdo, canvas.width / 5, canvas.height / 3.1); //Toxic Codes
  71. ctx.fillText(createdf, canvas.width / 5, canvas.height / 2.75); //Toxic Codes
  72. ctx.fillStyle = "#ffffff"; //Toxic Codes
  73. ctx.fillText(region, canvas.width / 1.2, canvas.height / 2.9); //Toxic Codes
  74. ctx.fillText(verificationl, canvas.width / 2.9, canvas.height / 6); //Toxic Codes
  75. ctx.fillText(roles, canvas.width / 1.5, canvas.height / 1.3); //Toxic Codes
  76. ctx.font = '30px Elephant';//Toxic Codes
  77. ctx.fillStyle = "#007cff"; //Toxic Codes
  78. ctx.fillText(tserverid, canvas.width / 6, canvas.height / 1.6); //Toxic Codes
  79. ctx.font = '30px Elephant';//Toxic Codes
  80. ctx.fillStyle = "#ffd304"; //Toxic Codes
  81. ctx.fillText(townerna, canvas.width / 6, canvas.height / 1.8); //Toxic Codes
  82. ctx.fillStyle = "#ffffff"; //Toxic Codes
  83. ctx.font = '30px Elephant';//Toxic Codes
  84. ctx.fillText(tchannels, canvas.width / 1.4, canvas.height / 6); //Toxic Codes
  85. ctx.fillText(tvoice, canvas.width / 1.4, canvas.height / 4.8); //Toxic Codes
  86. ctx.fillText(ttext, canvas.width / 1.4, canvas.height / 3.9); //Toxic Codes
  87. ctx.fillStyle = "#e9abab"; //Toxic Codes
  88. ctx.fillText(tcreatedo, canvas.width / 5, canvas.height / 3.6); //Toxic Codes
  89. ctx.fillStyle = "#ffffff"; //Toxic Codes
  90. ctx.font = '25px Elephant';//Toxic Codes
  91. ctx.fillText(tregion, canvas.width / 1.5, canvas.height / 2.9); //Toxic Codes
  92. ctx.fillText(tverificationl, canvas.width / 5.5, canvas.height / 6); //Toxic Codes
  93. ctx.font = '30px Elephant';//Toxic Codes
  94. ctx.fillText(troles, canvas.width / 1.8, canvas.height / 1.3); //Toxic Codes
  95. ctx.font = '25px Elephant';//Toxic Codes
  96. ctx.fillText(hm, canvas.width / 4.3, canvas.height / 1.1); //Toxic Codes
  97. ctx.font = '30px Elephant';//Toxic Codes
  98. ctx.fillStyle = "#ff0000"; //Toxic Codes
  99. ctx.fillText(tmembers, canvas.width / 5, canvas.height / 1.4); //Toxic Codes
  100. ctx.fillStyle = "#00ff70"; //Toxic Codes
  101. ctx.fillText(tonline, canvas.width / 4.3, canvas.height / 1.3); //Toxic Codes
  102. ctx.fillStyle = "#ff0000"; //Toxic Codes
  103. ctx.font = '25px Elephant';//Toxic Codes
  104. ctx.fillText(members, canvas.width / 2.5, canvas.height / 1.4); //Toxic Codes
  105. ctx.fillStyle = "#00ff70"; //Toxic Codes
  106. ctx.fillText(online, canvas.width / 2.5, canvas.height / 1.3); //Toxic Codes
  107. ctx.fillStyle = "#ffffff"; //Toxic Codes
  108. ctx.fillText(by, canvas.width / 1.99, canvas.height / 1.1); //Toxic Codes
  109. ctx.drawImage(avatar, 50, 410, 50, 50); //Toxic Codes
  110. ctx.strokeStyle = '#74037b'; //Toxic Codes
  111. ctx.strokeRect(0, 0, canvas.width, canvas.height); //Toxic Codes
  112. ctx.beginPath(); //Toxic Codes
  113. ctx.arc(394, 125, 85, 0, Math.PI * 2, true); //Toxic Codes
  114. ctx.closePath(); //Toxic Codes
  115. ctx.clip(); //Toxic Codes
  116. ctx.drawImage(icon, 309, 40, 170, 170); //Toxic Codes
  117. msg.channel.sendFile(canvas.toBuffer()) //Toxic Codes
  118. }//Toxic Codes
  119. }//Toxic Codes
  120. });//Toxic Codes
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement