diff options
| author | MegaMech <MegaMech@users.noreply.github.com> | 2024-07-26 11:29:35 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-26 11:29:35 -0600 |
| commit | 532ad5a4c03d7098b316ac1ebf2c467525442791 (patch) | |
| tree | 258d8b8b206efab661fa69c92121718b08b5a9d7 /src/port/ui/ImguiUI.cpp | |
| parent | dd5844ab81ebe3e429b8810e16ececb6b56219bc (diff) | |
Renames & seg 3 & 5 texture fixes (#19)
* Remove tools/torch
* Auto compile torch and extract
* Re-implement soh's implementation of lus implementation of an array
* Fix static actors in mr
* Update
* Updated torch
* Updated lus
* uncomment
* Fix collision
* Renames
* More renaming
* Collision Renames
* Update collision.c
* Collision Documentation (#640)
* Collision related renames
* Update
* update lus
* Bug fixes
* remove tabs
* fixes
* fixes
* Fix kart textures
* Networking
* net
* Add networking
* Update
* Cleanup
* Fix balloon rendering
* Fix lakitu and red shell
* fixes
* Implement new random system
---------
Co-authored-by: MegaMech <7255464+MegaMech@users.noreply.github.com>
Diffstat (limited to 'src/port/ui/ImguiUI.cpp')
| -rw-r--r-- | src/port/ui/ImguiUI.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/port/ui/ImguiUI.cpp b/src/port/ui/ImguiUI.cpp index 34ccdaca2..46f1adfa6 100644 --- a/src/port/ui/ImguiUI.cpp +++ b/src/port/ui/ImguiUI.cpp @@ -1,6 +1,7 @@ #include "ImguiUI.h" #include "UIWidgets.h" #include "ResolutionEditor.h" +#include "GameInfoWindow.h" #include <spdlog/spdlog.h> #include <imgui.h> @@ -22,6 +23,7 @@ std::shared_ptr<Ship::GuiWindow> mConsoleWindow; std::shared_ptr<Ship::GuiWindow> mStatsWindow; std::shared_ptr<Ship::GuiWindow> mInputEditorWindow; std::shared_ptr<Ship::GuiWindow> mGfxDebuggerWindow; +std::shared_ptr<Ship::GuiWindow> mGameInfoWindow; std::shared_ptr<AdvancedResolutionSettings::AdvancedResolutionSettingsWindow> mAdvancedResolutionSettingsWindow; void SetupGuiElements() { @@ -34,6 +36,12 @@ void SetupGuiElements() { mGameMenuBar = std::make_shared<GameMenuBar>("gOpenMenuBar", CVarGetInteger("gOpenMenuBar", 0)); gui->SetMenuBar(mGameMenuBar); + + mGameInfoWindow = gui->GetGuiWindow("GameInfo"); + if (mGameInfoWindow == nullptr) { + SPDLOG_ERROR("Could not find game info window"); + } + mStatsWindow = gui->GetGuiWindow("Stats"); if (mStatsWindow == nullptr) { SPDLOG_ERROR("Could not find stats window"); @@ -55,12 +63,16 @@ void SetupGuiElements() { SPDLOG_ERROR("Could not find input GfxDebuggerWindow"); } + mGameInfoWindow = std::make_shared<GameInfo::GameInfoWindow>("gGameInfoEnabled", "Game info"); + gui->AddGuiWindow(mGameInfoWindow); + mAdvancedResolutionSettingsWindow = std::make_shared<AdvancedResolutionSettings::AdvancedResolutionSettingsWindow>("gAdvancedResolutionEditorEnabled", "Advanced Resolution Settings"); gui->AddGuiWindow(mAdvancedResolutionSettingsWindow); } void Destroy() { mAdvancedResolutionSettingsWindow = nullptr; + mGameInfoWindow = nullptr; mConsoleWindow = nullptr; mStatsWindow = nullptr; mInputEditorWindow = nullptr; @@ -476,6 +488,10 @@ void DrawDebugMenu() { UIWidgets::Spacer(0); + UIWidgets::WindowButton("GameInfo", "gGameInfoEnabled", GameUI::mGameInfoWindow, { + .tooltip = "Shows the game info window, contains player and actor information" + }); + UIWidgets::WindowButton("Stats", "gStatsEnabled", GameUI::mStatsWindow, { .tooltip = "Shows the stats window, with your FPS and frametimes, and the OS you're playing on" }); |
