use games::*; fn main() { App::new() .add_plugins((BaseGamePlugin { name: "2d game example".into(), game_type: GameType::Two, },)) .add_systems(Startup, spawn_guy) .run(); } fn spawn_guy( mut commands: Commands, server: Res, mut meshes: ResMut>, mut materials: ResMut>, ) { let material = MeshMaterial2d(materials.add(ColorMaterial { texture: Some(server.load("flappy/bevy.png")), ..default() })); let mesh = Mesh2d(meshes.add(Rectangle::new(100.0, 100.0))); let name = Name::new("lil guy"); let t = Transform::from_xyz(0.0, 0.0, 0.0); commands.spawn((name, material, mesh, t)); }