feat(Network): Send Chat Message (#594)
This commit is contained in:
@ -2,6 +2,8 @@
|
||||
#include "fiber_pool.hpp"
|
||||
#include "util/session.hpp"
|
||||
#include "core/data/region_codes.hpp"
|
||||
#include "gta_util.hpp"
|
||||
#include "util/notify.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
@ -44,6 +46,19 @@ namespace big
|
||||
ImGui::Checkbox("Disable Filter", &g->session.disable_chat_filter);
|
||||
ImGui::Checkbox("Log Chat Messages", &g->session.log_chat_messages);
|
||||
ImGui::Checkbox("Log Text Messages", &g->session.log_text_messages);
|
||||
static char msg[256];
|
||||
ImGui::InputText("##message", msg, sizeof(msg));
|
||||
ImGui::SameLine();
|
||||
ImGui::Checkbox("Is Team", &g->session.is_team);
|
||||
ImGui::SameLine();
|
||||
components::button("Send", []
|
||||
{
|
||||
if(const auto net_game_player = gta_util::get_network_player_mgr()->m_local_net_player; net_game_player)
|
||||
{
|
||||
if(g_pointers->m_send_chat_message(*g_pointers->m_send_chat_ptr, net_game_player->get_net_data(), msg, g->session.is_team))
|
||||
notify::draw_chat(msg, net_game_player->get_name(), g->session.is_team);
|
||||
}
|
||||
});
|
||||
|
||||
components::sub_title("Decloak");
|
||||
components::script_patch_checkbox("Reveal OTR Players", &g->session.decloak_players);
|
||||
|
Reference in New Issue
Block a user