2022-10-26 14:12:29 +02:00
|
|
|
#include "views/view.hpp"
|
2022-05-04 19:16:40 +02:00
|
|
|
#include "fiber_pool.hpp"
|
|
|
|
#include "util/session.hpp"
|
2022-11-12 07:13:01 +08:00
|
|
|
#include "core/data/region_codes.hpp"
|
2022-05-04 19:16:40 +02:00
|
|
|
|
|
|
|
namespace big
|
|
|
|
{
|
2022-07-06 11:59:08 +02:00
|
|
|
void view::session()
|
|
|
|
{
|
2022-10-26 14:12:29 +02:00
|
|
|
static uint64_t rid = 0;
|
|
|
|
ImGui::InputScalar("Input RID", ImGuiDataType_U64, &rid);
|
|
|
|
components::button("Join RID", []
|
|
|
|
{
|
|
|
|
session::join_by_rockstar_id(rid);
|
|
|
|
});
|
|
|
|
|
2022-08-10 08:42:34 +08:00
|
|
|
components::sub_title("Session Switcher");
|
2022-07-06 11:59:08 +02:00
|
|
|
if (ImGui::ListBoxHeader("###session_switch"))
|
2022-05-04 19:16:40 +02:00
|
|
|
{
|
2022-07-06 11:59:08 +02:00
|
|
|
for (const auto& session_type : sessions)
|
|
|
|
{
|
2022-10-26 14:12:29 +02:00
|
|
|
components::selectable(session_type.name, false, [&session_type]
|
2022-10-19 00:30:32 +02:00
|
|
|
{
|
|
|
|
session::join_type(session_type.id);
|
2022-07-06 11:59:08 +02:00
|
|
|
});
|
|
|
|
}
|
|
|
|
ImGui::EndListBox();
|
2022-05-04 19:16:40 +02:00
|
|
|
}
|
2022-11-12 07:13:01 +08:00
|
|
|
|
|
|
|
components::sub_title("Region Switcher");
|
|
|
|
if (ImGui::ListBoxHeader("###region_switch"))
|
|
|
|
{
|
|
|
|
for (const auto& region_type : regions)
|
|
|
|
{
|
|
|
|
components::selectable(region_type.name, *g_pointers->m_region_code == region_type.id, [®ion_type]
|
|
|
|
{
|
|
|
|
*g_pointers->m_region_code = region_type.id;
|
|
|
|
});
|
|
|
|
}
|
|
|
|
ImGui::EndListBox();
|
|
|
|
}
|
2022-10-26 15:38:01 -04:00
|
|
|
|
2022-10-29 05:54:32 -04:00
|
|
|
components::sub_title("Chat");
|
|
|
|
ImGui::Checkbox("Disable Filter", &g->session.disable_chat_filter);
|
2022-11-12 03:17:22 +10:30
|
|
|
ImGui::Checkbox("Log Chat Messages", &g->session.log_chat_messages);
|
|
|
|
ImGui::Checkbox("Log Text Messages", &g->session.log_text_messages);
|
2022-11-12 18:35:28 +00:00
|
|
|
|
|
|
|
components::sub_title("Decloak");
|
|
|
|
components::script_patch_checkbox("Reveal OTR Players", &g->session.decloak_players);
|
2022-05-04 19:16:40 +02:00
|
|
|
}
|
2022-10-26 14:12:29 +02:00
|
|
|
}
|