Files
osmium/examples/cube.rs
T
2025-11-26 10:57:21 +01:00

20 lines
338 B
Rust

use osmium::entity::Component;
pub struct Velocity(pub i32);
impl Component for Velocity {
fn tick(&mut self) {}
}
fn main() {
let mut engine = osmium::init();
engine.thread("Main.tick", || {});
let mut my_rect = engine.draw(|r| {
// r.draw_rect(0, 0, 10, 10);
});
my_rect.component(Velocity(10));
}