2021-09-16 22:21:42 +02:00
|
|
|
#include "handling_tabs.hpp"
|
|
|
|
|
|
|
|
namespace big
|
|
|
|
{
|
|
|
|
void tab_handling::tab_current_profile()
|
|
|
|
{
|
|
|
|
if (ImGui::BeginTabItem("Current Profile"))
|
|
|
|
{
|
2021-09-18 22:15:45 +02:00
|
|
|
if (g_vehicle_service->get_active_profile(g_local_player->m_vehicle->m_handling->m_model_hash).empty())
|
2021-09-16 22:21:42 +02:00
|
|
|
{
|
2021-09-18 22:15:45 +02:00
|
|
|
if (ImGui::Button("Save Profile"))
|
|
|
|
{
|
|
|
|
ImGui::OpenPopup("Save Handling");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
if (ImGui::Button("Update Profile"))
|
|
|
|
{
|
|
|
|
ImGui::OpenPopup("Update Handling");
|
|
|
|
}
|
2021-09-16 22:21:42 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
modal_handling::modal_save_handling();
|
2021-09-18 22:15:45 +02:00
|
|
|
modal_handling::modal_update_handling();
|
2021-09-16 22:21:42 +02:00
|
|
|
ImGui::SameLine();
|
|
|
|
if (ImGui::Button("Restore Handling"))
|
|
|
|
g_vehicle_service->restore_vehicle();
|
|
|
|
|
|
|
|
ImGui::Separator();
|
|
|
|
|
|
|
|
ImGui::BeginTabBar("handling_tabbar");
|
|
|
|
tab_current_profile::tab_general();
|
|
|
|
tab_current_profile::tab_other();
|
|
|
|
tab_current_profile::tab_brakes();
|
|
|
|
tab_current_profile::tab_gearing();
|
|
|
|
tab_current_profile::tab_traction();
|
2022-01-31 17:27:59 +01:00
|
|
|
tab_current_profile::tab_transmission();
|
2021-09-16 22:21:42 +02:00
|
|
|
tab_current_profile::tab_steering();
|
|
|
|
tab_current_profile::tab_suspension();
|
|
|
|
tab_current_profile::tab_rollbars();
|
|
|
|
tab_current_profile::tab_roll_centre_height();
|
|
|
|
ImGui::EndTabBar();
|
|
|
|
|
|
|
|
ImGui::EndTabItem();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|