diff options
Diffstat (limited to 'mm/2s2h/ShipUtils.cpp')
| -rw-r--r-- | mm/2s2h/ShipUtils.cpp | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/mm/2s2h/ShipUtils.cpp b/mm/2s2h/ShipUtils.cpp index c92d2b9b8..b6d1cd2b9 100644 --- a/mm/2s2h/ShipUtils.cpp +++ b/mm/2s2h/ShipUtils.cpp @@ -17,6 +17,8 @@ #include "assets/objects/gameplay_keep/gameplay_keep.h" #include "assets/overlays/ovl_En_Syateki_Okuta/ovl_En_Syateki_Okuta.h" +#include <fast/Fast3dGui.h> + extern "C" { #include "z64.h" #include "functions.h" @@ -348,21 +350,26 @@ extern uint32_t Ship_Hash(std::string str) { void LoadGuiTextures() { for (const TexturePtr entry : gItemIcons) { auto path = static_cast<const char*>(entry); - Ship::Context::GetInstance()->GetWindow()->GetGui()->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); + std::dynamic_pointer_cast<Fast::Fast3dGui>(Ship::Context::GetRawInstance()->GetWindow()->GetGui()) + ->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); } for (const TexturePtr entry : gQuestIcons) { auto path = static_cast<const char*>(entry); - Ship::Context::GetInstance()->GetWindow()->GetGui()->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); + std::dynamic_pointer_cast<Fast::Fast3dGui>(Ship::Context::GetRawInstance()->GetWindow()->GetGui()) + ->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); } for (const TexturePtr entry : gBombersNotebookPhotos) { auto path = static_cast<const char*>(entry); - Ship::Context::GetInstance()->GetWindow()->GetGui()->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); + std::dynamic_pointer_cast<Fast::Fast3dGui>(Ship::Context::GetRawInstance()->GetWindow()->GetGui()) + ->LoadGuiTexture(path, path, ImVec4(1, 1, 1, 1)); } for (const auto entry : miscellaneousTextures) { - Ship::Context::GetInstance()->GetWindow()->GetGui()->LoadGuiTexture(entry, entry, ImVec4(1, 1, 1, 1)); + std::dynamic_pointer_cast<Fast::Fast3dGui>(Ship::Context::GetRawInstance()->GetWindow()->GetGui()) + ->LoadGuiTexture(entry, entry, ImVec4(1, 1, 1, 1)); } for (const auto entry : digitList) { - Ship::Context::GetInstance()->GetWindow()->GetGui()->LoadGuiTexture(entry, entry, ImVec4(1, 1, 1, 1)); + std::dynamic_pointer_cast<Fast::Fast3dGui>(Ship::Context::GetRawInstance()->GetWindow()->GetGui()) + ->LoadGuiTexture(entry, entry, ImVec4(1, 1, 1, 1)); } } |
