Integrated plugins with /help command

This commit is contained in:
James Booth
2016-02-18 21:53:20 +00:00
parent a152d7fb8e
commit 0ed3b53bd2
5 changed files with 53 additions and 11 deletions

View File

@@ -143,3 +143,18 @@ plugins_run_timed(void)
}
return;
}
GList*
plugins_get_command_names(void)
{
GList *result = NULL;
GSList *curr = p_commands;
while (curr) {
PluginCommand *command = curr->data;
result = g_list_append(result, (char*)command->command_name);
curr = g_slist_next(curr);
}
return result;
}

View File

@@ -101,6 +101,7 @@ void plugins_post_priv_message_send(const char * const jid, const char * const
gboolean plugins_run_command(const char * const cmd);
void plugins_run_timed(void);
GList* plugins_get_command_names(void);
gchar * plugins_get_dir(void);
CommandHelp* plugins_get_help(const char *const cmd);