toowake

ascii

Apr 9th, 2023
785
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. const { SlashCommandBuilder } = require("discord.js");
  2. const ascii = require('ascii-art');
  3.  
  4. module.exports = {
  5. data: new SlashCommandBuilder()
  6. .setName("ascii")
  7. .setDescription("Create Ascii Art")
  8. .addStringOption(option => option
  9. .setName("text")
  10. .setDescription("The text")
  11. .setRequired(true)
  12. ),
  13.  
  14. async execute (interaction) {
  15. const text = interaction.options.getString("text");
  16.  
  17. ascii.font(text, 'Doom', (err) => {
  18. interaction.reply(`\`\`\`${err}\`\`\``);
  19. });
  20. }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment