use bevy_ecs::prelude::*;
use bevy_ecs::system::EntityCommands;
use crate::cell::GeoCell;
use crate::origin::FloatingOrigin;
pub trait BevyA5Commands<'w, 's> {
fn spawn_floating_origin(&mut self, cell: GeoCell) -> EntityCommands<'_>;
fn spawn_cell_anchor(&mut self, cell: GeoCell) -> EntityCommands<'_>;
}
impl<'w, 's> BevyA5Commands<'w, 's> for Commands<'w, 's> {
fn spawn_floating_origin(&mut self, cell: GeoCell) -> EntityCommands<'_> {
self.spawn((FloatingOrigin::default(), cell))
}
fn spawn_cell_anchor(&mut self, cell: GeoCell) -> EntityCommands<'_> {
self.spawn(cell)
}
}