From fbbfdd4af6268bf03d59980315a9d8361e6c4be7 Mon Sep 17 00:00:00 2001 From: Sachin <31343375+Cruze03@users.noreply.github.com> Date: Fri, 23 Apr 2021 18:19:54 +0530 Subject: [PATCH] Update discord_utilities.inc --- scripting/include/discord_utilities.inc | 27 +++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/scripting/include/discord_utilities.inc b/scripting/include/discord_utilities.inc index afa978d..42b7711 100644 --- a/scripting/include/discord_utilities.inc +++ b/scripting/include/discord_utilities.inc @@ -3,6 +3,14 @@ #endif #define _discord_utilities_included +/** + * Called after a client's data has been retrieved from database. + * + * @param client Client index loaded client. + * @noreturn + */ +forward void DU_OnClientLoaded(int client); + /** * Called after a client has verfied his discord account. * @@ -33,6 +41,16 @@ forward void DU_OnAccountRevoked(int client, const char[] userid); */ forward void DU_OnCheckedAccounts(const char[] bottoken, const char[] guildid, const char[] tablename); + +/** + * Called before a blocked command being used by client. + * + * @param client Player who used command. + * @param command Command used. + * @return Continue to let him use, Handled to let plugin behave normally, Stop to stop him executing command manually. + */ +forward Action DU_OnBlockedCommandUse(int client, char[] command); + /** * Refreshing every client online in server. Can be used for grasping steam avatar of client and re-checking client in database. * @@ -89,6 +107,15 @@ native void DU_AddRole(int client, char[] roleid); */ native void DU_DeleteRole(int client, char[] roleid); +/** + * Checks role from client according to roleid + * @param client Client index to delete role from. + * @param roleid String containing roleid. + * @param maxsize Max size of string. + * @noreturn + */ +native void DU_CheckRole(int client, char[] roleid); + public SharedPlugin __pl_discord_utilities = { name = "DiscordUtilities",