mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-24 16:10:14 +00:00
feat: show estimated BG wait time in queue indicator
This commit is contained in:
parent
c31ab8c8b6
commit
792d8e1cf5
3 changed files with 18 additions and 4 deletions
|
|
@ -16630,8 +16630,15 @@ void GameScreen::renderMinimapMarkers(game::GameHandler& gameHandler) {
|
|||
ImGui::SetNextWindowSize(ImVec2(indicatorW, kIndicatorH), ImGuiCond_Always);
|
||||
if (ImGui::Begin("##BgQueueIndicator", nullptr, indicatorFlags)) {
|
||||
float pulse = 0.6f + 0.4f * std::sin(static_cast<float>(ImGui::GetTime()) * 1.5f);
|
||||
ImGui::TextColored(ImVec4(0.4f, 0.8f, 1.0f, pulse),
|
||||
"In Queue: %s", bgName.c_str());
|
||||
if (slot.avgWaitTimeSec > 0) {
|
||||
int avgMin = static_cast<int>(slot.avgWaitTimeSec) / 60;
|
||||
int avgSec = static_cast<int>(slot.avgWaitTimeSec) % 60;
|
||||
ImGui::TextColored(ImVec4(0.4f, 0.8f, 1.0f, pulse),
|
||||
"Queue: %s (~%d:%02d)", bgName.c_str(), avgMin, avgSec);
|
||||
} else {
|
||||
ImGui::TextColored(ImVec4(0.4f, 0.8f, 1.0f, pulse),
|
||||
"In Queue: %s", bgName.c_str());
|
||||
}
|
||||
}
|
||||
ImGui::End();
|
||||
nextIndicatorY += kIndicatorH;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue