Advertisement
Guest User

CODE POUR L'IP RADAMYY

a guest
Feb 24th, 2020
251
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.74 KB | None | 0 0
  1. const { Client, Util } = require('discord.js');
  2. const Discord = require('discord.js');
  3. const client = new Client();
  4.  
  5. var prefix = "!"; //hada le prefix
  6.  
  7. const commands = {
  8. 'zab': (msg) => { //hna la commande li briri
  9. let ip_dial_zab = "mc.radamyy.ml";
  10. let serverport_fromfield = serverip.split(':')[1];
  11. var site = "http://radamyy.rf.gd";
  12. if (!ip_dial_zab) {
  13.  
  14. msg.channel.sendMessage(msg.author + " | Aucune IP n'est renseiger. :x:");
  15.  
  16. } else {
  17.  
  18. if (!ip_dial_zab.includes(":")) {
  19. ip_dial_zab_final = ip_dial_zab;
  20. } else {
  21. ip_dial_zab_final = serverip_fromfield;
  22. }
  23.  
  24. if (!serverport_fromfield) {
  25. var port_dial_zab_final = "25565";
  26. } else {
  27. var port_dial_zab_final = serverport_fromfield;
  28. }
  29.  
  30. const embed = new Discord.RichEmbed()
  31. .setTitle("Status de " + ip_dial_zab)
  32. .setColor(0x00AE86)
  33. .setFooter("Minecraft server status", "")
  34. .setImage("http://status.mclive.eu/Server/" + ip_dial_zab_final + "/" + port_dial_zab_final + "/banner.png")
  35. .setTimestamp()
  36. .addField("Ip du serveur",ip_dial_zab)
  37. .setTimestamp()
  38. .addField("Fondateurs","Kofyy et Milkyy")
  39. .setTimestamp()
  40. .addField("Site web",site)
  41.  
  42. msg.channel.send({embed});
  43.  
  44.  
  45. }
  46.  
  47. }
  48. };
  49.  
  50. client.on('message', msg => {
  51. if (!msg.content.startsWith(prefix)) return;
  52. if (commands.hasOwnProperty(msg.content.toLowerCase().slice(prefix.length).split(' ')[0])) commands[msg.content.toLowerCase().slice(prefix.length).split(' ')[0]](msg);
  53. });
  54.  
  55. client.login("NjgxNjEyMDE0NzI0MDU1MDQy.XlRDPA.lhNHulAIVqBj0W9yQy95FXxeSWk");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement