fix uninitialized f32 causing crash in palace of twilight, add FPS to menu bar

This commit is contained in:
CraftyBoss
2026-03-16 15:43:42 -07:00
parent 61d2ba1e33
commit e751e3b3da
2 changed files with 9 additions and 0 deletions
+5
View File
@@ -704,8 +704,13 @@ static int daKytag12_Execute_R00(kytag12_class* i_this) {
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
dKankyo_evil_Packet* temp_r25 = dKy_getEnvlight()->mpEvilPacket;
#if AVOID_UB
f32 var_f26 = 0;
f32 var_f25 = 0;
#else
f32 var_f26;
f32 var_f25;
#endif
int var_r24 = 0;
+4
View File
@@ -95,6 +95,10 @@ namespace dusk {
m_menuGame.draw();
m_menuTools.draw();
ImGui::SetCursorPosX(ImGui::GetWindowWidth() - 80.0f);
ImGuiIO& io = ImGui::GetIO();
ImGuiStringViewText(fmt::format(FMT_STRING("FPS: {:.2f}\n"), io.Framerate));
ImGui::EndMainMenuBar();
}
}