Skip to content

Commit

Permalink
hud
Browse files Browse the repository at this point in the history
  • Loading branch information
Dregu committed May 27, 2024
1 parent cbb2cd6 commit dcf6c54
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,21 @@ void UI::Draw() {
}
}

if (windowScale > 2) {
std::string hud = fmt::format(
"{}{}{} ROOM:{},{} POS:{:.0f},{:.0f}",
options["cheat_damage"].value ? " DAMAGE" : "",
options["cheat_noclip"].value ? " NOCLIP" : "",
options["cheat_godmode"].value ? " GOD" : "",
Max::get().player_room()->x, Max::get().player_room()->y,
Max::get().player_position()->x, Max::get().player_position()->y);
ImGui::GetForegroundDrawList()->AddText(
ImVec2(io.DisplaySize.x - ImGui::CalcTextSize(hud.c_str()).x -
ImGui::GetStyle().WindowPadding.x,
0),
0xffffffff, hud.c_str());
}

{
using namespace std::chrono_literals;
auto now = std::chrono::system_clock::now();
Expand Down

0 comments on commit dcf6c54

Please sign in to comment.