dreamwell-runtime 1.0.0

Dreamwell Runtime — cross-platform GPU-accelerated game client
Documentation
// Scene — bridges engine GameObjectScene to GPU rendering via GpuScene.
// All game objects live in `GameObjectScene`. Legacy `SceneEntity` removed in v1.0.0.

use dreamwell_engine::game_object::GameObjectScene;
use dreamwell_gpu::camera::Camera;

/// The runtime scene — holds the engine scene and camera.
pub struct Scene {
    pub camera: Camera,
    /// Engine-side game object scene (primitives, components, hierarchy).
    pub game_objects: GameObjectScene,
}

impl Default for Scene {
    fn default() -> Self {
        Self {
            camera: Camera::default(),
            game_objects: GameObjectScene::new("Runtime".into()),
        }
    }
}

impl Scene {
    /// Number of game objects in the scene.
    pub fn object_count(&self) -> usize {
        self.game_objects.len()
    }
}