package com.nincraft.ninbot.command;

import com.nincraft.ninbot.command.util.CommandParser;
import com.nincraft.ninbot.util.MessageUtils;
import lombok.val;
import net.dv8tion.jda.core.events.message.MessageReceivedEvent;

public class HelpCommand extends AbstractCommand {

    public HelpCommand() {
        length = 2;
        name = "help";
        description = "Displays this awesome message";
    }

    @Override
    public void executeCommand(MessageReceivedEvent event) {
        val map = CommandParser.getCommandHashMap();
        StringBuilder stringBuilder = new StringBuilder();
        for (val key : map.keySet()) {
            if (!map.get(key).isHidden()) {
                stringBuilder.append(map.get(key));
                stringBuilder.append("\n");
            }
        }
        MessageUtils.sendMessage(event.getChannel(), stringBuilder.toString());
    }
}

@@ -183,42 +183,229 @@
 ore.
-events.message.MessageReceivedEven
+EmbedBuilder;%0Aimport net.dv8tion.jda.core.MessageBuilder;%0Aimport net.dv8tion.jda.core.events.message.MessageReceivedEvent;%0A%0Aimport java.awt.*;%0Aimport java.util.ArrayList;%0Aimport java.util.Collections;%0Aimport java.util.Lis
 t;%0A%0A
@@ -728,22 +728,23 @@
     
-String
+Message
 Builder 
 stri
@@ -739,22 +739,23 @@
 Builder 
-string
+message
 Builder 
@@ -764,60 +764,303 @@
 new 
-StringBuilder();%0A        for (val key : map.keySet()
+MessageBuilder();%0A        EmbedBuilder embedBuilder = new EmbedBuilder();%0A        embedBuilder.setTitle(%22List of commands%22);%0A        embedBuilder.setColor(Color.BLUE);%0A        List%3CString%3E keyList = new ArrayList%3C%3E(map.keySet());%0A        Collections.sort(keyList);%0A        for (val key : keyList
 ) %7B%0A
@@ -1111,38 +1111,37 @@
                 
-string
+embed
 Builder.append(m
@@ -1137,26 +1137,57 @@
 er.a
-ppend(map.get(key)
+ddField(key, map.get(key).getDescription(), false
 );%0A 
@@ -1200,64 +1200,75 @@
     
+ %7D%0A
      
-stringBuilder.append(%22%5Cn%22);%0A            %7D%0A        %7D
+   %7D%0A        messageBuilder.setEmbed(embedBuilder.build());
 %0A   
@@ -1321,22 +1321,23 @@
 (), 
-string
+message
 Builder.
 toSt
@@ -1336,16 +1336,13 @@
 der.
-toString
+build
 ());

Make Help command more fancy