/[sudobot]/trunk/src/services/CommandMetaDataManager.ts
ViewVC logotype

Diff of /trunk/src/services/CommandMetaDataManager.ts

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 72 by rakin, Mon Jul 29 17:28:29 2024 UTC revision 295 by rakin, Mon Jul 29 17:29:24 2024 UTC
# Line 12  export function findCommandData(callback Line 12  export function findCommandData(callback
12      return Help.find(callback);      return Help.find(callback);
13  }  }
14    
15  export function renderCommandList(): string {  export function renderCommandList(limit = 40): string {
16      let str = `Type \`${DiscordClient.client.config.get('prefix')}help <CommandName>\` for more information about a specific command.\n\n`;      let str = `Type \`${DiscordClient.client.config.get('prefix')}help <CommandName>\` for more information about a specific command.\n\n`;
17        let index = 0;
18    
19      for (const cmd of Help) {      for (const cmd of Help) {
20            if (limit <= index)
21                break;
22    
23          str += `**${cmd.name}**\n${cmd.shortBrief}\n\n`;          str += `**${cmd.name}**\n${cmd.shortBrief}\n\n`;
24            index++;
25      }      }
26    
27      return str;      return str;

Legend:
Removed from v.72  
changed lines
  Added in v.295

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26