Update WIP discord and some vendors.

CPR has features disabled and PCRE is fully disabled until updated to new code.
This commit is contained in:
Sandu Liviu Catalin committed 2023-08-05 21:31:33 +03:00
1 parent e0761bf3b9
commit 9298065cef
1562 files changed
+55070 -76299

No files matched your search

+55 -16
View File
@@ -40,6 +40,7 @@
#include <dpp/scheduled_event.h>
#include <dpp/stage_instance.h>
#include <dpp/integration.h>
#include <dpp/auditlog.h>
#include <functional>
#include <variant>
#include <exception>
@@ -473,17 +474,6 @@ struct DPP_EXPORT interaction_create_t : public event_dispatch_t {
*/
void delete_original_response(command_completion_event_t callback = utility::log_error()) const;
/**
* @brief Get a command line parameter
*
* @note Doesn't work on subcommands. If you want to get a parameter from a subcommand, you have to loop through the options by yourself.
*
* @param name The command line parameter to retrieve
* @return const command_value& If the command line parameter does not
* exist, an empty variant is returned.
*/
const virtual command_value& get_parameter(const std::string& name) const;
/**
* @brief command interaction
*/
@@ -493,13 +483,24 @@ struct DPP_EXPORT interaction_create_t : public event_dispatch_t {
* @brief Destroy this object
*/
virtual ~interaction_create_t() = default;
/**
* @brief Get a slashcommand parameter
*
* @param name The name of the command line parameter to retrieve the value for
* @return command_value Returns the value of the first option that matches the given name.
* If no matches are found, an empty variant is returned.
*
* @throw dpp::logic_exception if the interaction is not for a command
*/
virtual command_value get_parameter(const std::string& name) const;
};
/**
* @brief User has issued a slash command
*/
struct DPP_EXPORT slashcommand_t : public interaction_create_t {
public:
/** Constructor
* @param client The shard the event originated on
* @param raw Raw event text as JSON
@@ -514,6 +515,7 @@ struct DPP_EXPORT button_click_t : public interaction_create_t {
private:
using interaction_create_t::get_parameter;
public:
/** Constructor
* @param client The shard the event originated on
* @param raw Raw event text as JSON
@@ -534,6 +536,7 @@ struct DPP_EXPORT form_submit_t : public interaction_create_t {
private:
using interaction_create_t::get_parameter;
public:
/** Constructor
* @param client The shard the event originated on
* @param raw Raw event text as JSON
@@ -585,7 +588,10 @@ public:
* user or message.
*/
struct DPP_EXPORT context_menu_t : public interaction_create_t {
private:
using interaction_create_t::get_parameter;
public:
/** Constructor
* @param client The shard the event originated on
* @param raw Raw event text as JSON
@@ -910,7 +916,12 @@ struct DPP_EXPORT message_reaction_add_t : public event_dispatch_t {
*/
guild_member reacting_member;
/**
* @brief channel the reaction happened on
* @brief Channel ID the reaction happened on
*/
snowflake channel_id;
/**
* @brief channel the reaction happened on (Optional)
* @note only filled when the channel is cached
*/
channel* reacting_channel;
/**
@@ -956,7 +967,12 @@ struct DPP_EXPORT message_reaction_remove_t : public event_dispatch_t {
*/
dpp::snowflake reacting_user_id;
/**
* @brief channel the reaction happened on
* @brief Channel ID the reaction was removed in
*/
snowflake channel_id;
/**
* @brief channel the reaction happened on (optional)
* @note only filled when the channel is cached
*/
channel* reacting_channel;
/**
@@ -1034,7 +1050,12 @@ struct DPP_EXPORT message_reaction_remove_emoji_t : public event_dispatch_t {
*/
guild* reacting_guild;
/**
* @brief channel the reaction happened on
* @brief Channel ID the reactions was removed in
*/
snowflake channel_id;
/**
* @brief channel the reaction happened on (optional)
* @note only filled when the channel is cached
*/
channel* reacting_channel;
/**
@@ -1143,7 +1164,12 @@ struct DPP_EXPORT message_reaction_remove_all_t : public event_dispatch_t {
*/
guild* reacting_guild;
/**
* @brief channel the reaction happened on
* @brief Channel ID the reactions was removed in
*/
snowflake channel_id;
/**
* @brief channel the reaction happened on (optional)
* @note only filled when the channel is cached
*/
channel* reacting_channel;
/**
@@ -1395,6 +1421,19 @@ struct DPP_EXPORT message_create_t : public event_dispatch_t {
void reply(message&& msg, bool mention_replied_user = false, command_completion_event_t callback = utility::log_error()) const;
};
/** @brief Guild audit log entry create */
struct DPP_EXPORT guild_audit_log_entry_create_t : public event_dispatch_t {
/** Constructor
* @param client The shard the event originated on
* @param raw Raw event text as JSON
*/
guild_audit_log_entry_create_t(class discord_client* client, const std::string& raw);
/**
* @brief created audit log entry
*/
audit_entry entry;
};
/** @brief Guild ban add */
struct DPP_EXPORT guild_ban_add_t : public event_dispatch_t {
/** Constructor