feat: Translation Service (#844)

Co-authored-by: mrwoowoo <github@hiqaq.com>
Co-authored-by: LiamD-Flop <40887493+LiamD-Flop@users.noreply.github.com>
This commit is contained in:
Yimura
2023-02-01 19:46:33 +01:00
committed by GitHub
parent e95e7d1b47
commit 8028db84b3
79 changed files with 1183 additions and 779 deletions

View File

@ -13,36 +13,36 @@ namespace big
if (g_gta_data_service->cache_needs_update())
{
g_gui->toggle(true);
ImGui::OpenPopup("Game Cache");
ImGui::OpenPopup("GAME_CACHE"_T.data());
}
ImGui::SetNextWindowSize({ 800, 210 }, ImGuiCond_FirstUseEver);
ImGui::SetNextWindowPos({ 200, 200 }, ImGuiCond_FirstUseEver);
if (ImGui::BeginPopupModal("Game Cache"))
if (ImGui::BeginPopupModal("GAME_CACHE"_T.data()))
{
switch (g_gta_data_service->state())
{
case eGtaDataUpdateState::NEEDS_UPDATE:
{
ImGui::Text("YimMenu requires a rebuild of the game cache. This may take up to one minute to generate.");
ImGui::Text("GAME_CACHE_UPDATE"_T.data());
if (*g_pointers->m_is_session_started)
{
if (ImGui::Button("Update Cache"))
if (ImGui::Button("GAME_CACHE_UPDATE_CACHE"_T.data()))
{
g_gta_data_service->update_now();
}
}
else
{
ImGui::TextWrapped("You are currently in single player, you can force build the cache in single player but risk crashing when going into multiplayer or load online and cache.");
ImGui::TextWrapped("GAME_CACHE_SINGLE_PLAYER_DESCRIPTION"_T.data());
if (ImGui::Button("I don't care, update in single player!"))
if (ImGui::Button("GAME_CACHE_DONT_CARE"_T.data()))
{
g_gta_data_service->update_now();
}
if (ImGui::Button("Update cache in online."))
if (ImGui::Button("GAME_CACHE_GO_ONLINE"_T.data()))
{
g_gta_data_service->update_in_online();
}
@ -52,13 +52,13 @@ namespace big
}
case eGtaDataUpdateState::WAITING_FOR_ONLINE:
{
ImGui::Text("Waiting for online to start cache update...");
ImGui::Text("GAME_CACHE_WAITING_FOR_ONLINE"_T.data());
break;
}
case eGtaDataUpdateState::UPDATING:
{
ImGui::Text("Updating cache, please wait...");
ImGui::Text("GAME_CACHE_UPDATING"_T.data());
break;
}