mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2025-07-01 12:02:55 +08:00
feat(GTA Cache): removed unused old code (#1663)
This commit is contained in:
@ -16,18 +16,10 @@ namespace big
|
||||
components::sub_title("GTA cache stats:");
|
||||
ImGui::Text("Peds Cached: %d\nVehicles Cached: %d\nWeapons Cached: %d", ped_count, veh_count, wep_count);
|
||||
|
||||
if (components::button("Rebuild Cache in Online"))
|
||||
if (components::button("Rebuild Cache"))
|
||||
{
|
||||
g_gta_data_service->set_state(eGtaDataUpdateState::NEEDS_UPDATE);
|
||||
|
||||
if (!*g_pointers->m_gta.m_is_session_started)
|
||||
{
|
||||
g_gta_data_service->update_in_online();
|
||||
}
|
||||
else
|
||||
{
|
||||
g_gta_data_service->update_now();
|
||||
}
|
||||
g_gta_data_service->update_now();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -26,27 +26,9 @@ namespace big
|
||||
{
|
||||
ImGui::Text("GAME_CACHE_UPDATE"_T.data());
|
||||
|
||||
if (*g_pointers->m_gta.m_is_session_started)
|
||||
if (ImGui::Button("GAME_CACHE_UPDATE_CACHE"_T.data()))
|
||||
{
|
||||
if (ImGui::Button("GAME_CACHE_UPDATE_CACHE"_T.data()))
|
||||
{
|
||||
g_gta_data_service->update_now();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ImGui::Button("GAME_CACHE_UPDATE_CACHE"_T.data()))
|
||||
{
|
||||
g_gta_data_service->update_now();
|
||||
}
|
||||
|
||||
if (*g_pointers->m_gta.m_game_state == eGameState::Respawn)
|
||||
{
|
||||
if (ImGui::Button("GAME_CACHE_ON_INIT"_T.data()))
|
||||
{
|
||||
g_gta_data_service->update_on_init();
|
||||
}
|
||||
}
|
||||
g_gta_data_service->update_now();
|
||||
}
|
||||
|
||||
break;
|
||||
@ -57,30 +39,12 @@ namespace big
|
||||
|
||||
break;
|
||||
}
|
||||
case eGtaDataUpdateState::WAITING_FOR_ONLINE:
|
||||
{
|
||||
ImGui::Text("GAME_CACHE_WAITING_FOR_ONLINE"_T.data());
|
||||
|
||||
break;
|
||||
}
|
||||
case eGtaDataUpdateState::UPDATING:
|
||||
{
|
||||
ImGui::Text("GAME_CACHE_UPDATING"_T.data());
|
||||
|
||||
break;
|
||||
}
|
||||
case eGtaDataUpdateState::ON_INIT_WAITING:
|
||||
{
|
||||
ImGui::Text("GAME_CACHE_WAITING_FOR_SINGLE_PLAYER"_T.data());
|
||||
|
||||
break;
|
||||
}
|
||||
case eGtaDataUpdateState::ON_INIT_UPDATE_START:
|
||||
{
|
||||
ImGui::Text("GAME_CACHE_UPDATING"_T.data());
|
||||
|
||||
break;
|
||||
}
|
||||
case eGtaDataUpdateState::IDLE:
|
||||
{
|
||||
ImGui::CloseCurrentPopup();
|
||||
|
Reference in New Issue
Block a user