This commit is contained in:
LunarAkai 2025-08-04 23:06:15 +02:00
commit 022fac5966
8 changed files with 150 additions and 13 deletions

View file

@ -2,6 +2,8 @@
use std::rc::Rc;
use moonhare_ecs::world::World;
use moonhare_graphics::{color::Color, glium::{backend::Context, glutin::api::egl::context}};
use moonhare_log::*;
use moonhare_window::{platforms::glfw_window::GLFWWindow};
@ -10,19 +12,17 @@ pub mod basic;
/// Only one Game may exist per project
#[derive(Debug)]
pub struct Game {
pub world: World,
pub is_running: bool,
pub name: String,
pub context: moonhare_window::WindowRenderContext,
pub glfw_window: Option<moonhare_window::platforms::glfw_window::GLFWWindow>,
}
impl Default for Game {
fn default() -> Self {
Self {
world: World::new(),
is_running: true,
name: default_game_name(),
context: moonhare_window::WindowRenderContext::OPENGLGLFW,
glfw_window: None,
}
}
}