feat: add about tab item

This commit is contained in:
2026-04-26 21:13:05 +08:00
parent bd5665c935
commit 5b2f06b3ec
2 changed files with 25 additions and 0 deletions

View File

@@ -42,6 +42,7 @@ private:
TextEditing m_text_editing; TextEditing m_text_editing;
bool m_need_save_config = false; bool m_need_save_config = false;
int m_theme = 0; int m_theme = 0;
void show_about_table_bar();
void show_biome_table_bar(); void show_biome_table_bar();
void show_settings_tab_item(); void show_settings_tab_item();
void show_world_tab_item(); void show_world_tab_item();

View File

@@ -76,6 +76,7 @@ void DevPanel::render() {
show_settings_tab_item(); show_settings_tab_item();
show_world_tab_item(); show_world_tab_item();
show_player_tab_item(); show_player_tab_item();
show_about_table_bar();
ImGui::EndTabBar(); ImGui::EndTabBar();
} }
ImGui::End(); ImGui::End();
@@ -84,6 +85,29 @@ void DevPanel::render() {
} }
void DevPanel::show_about_table_bar() {
if (ImGui::BeginTabItem("about")) {
ImGui::Text("Cubed - A cube game like Minecraft, using C++ and OpenGL.");
ImGui::Text("Author: zhenyan121");
ImGui::Separator();
ImGui::Text("Libraries Used");
ImGui::Text("glad");
ImGui::Text("GLFW");
ImGui::Text("SOIL2");
ImGui::Text("GLM");
ImGui::Text("FreeType");
ImGui::Text("toml++");
ImGui::Text("Dear ImGui");
ImGui::Separator();
ImGui::Text("Special Thanks");
ImGui::Text("TANGERIME");
ImGui::Text("SkyOnPole");
ImGui::Text("free_w_cloud");
ImGui::Text("Last but not least, thanks to you");
ImGui::EndTabItem();
}
}
void DevPanel::show_biome_table_bar() { void DevPanel::show_biome_table_bar() {
ImGui::Text("Biome"); ImGui::Text("Biome");
if (ImGui::BeginTabBar("Biome")) { if (ImGui::BeginTabBar("Biome")) {