separate scope differently in the macro
This commit is contained in:
parent
7070fb0357
commit
923e0dc42b
@ -31,7 +31,7 @@ use visibility_system::VisibilitySystem;
|
||||
macro_rules! register {
|
||||
// $gs is needed to get the scope at the usage point
|
||||
// $Type is the Component type that is being registered
|
||||
($gs: ident, $( $Type: ty ),*,) => {
|
||||
($gs: ident <- $( $Type: ty ),*,) => {
|
||||
$(
|
||||
$gs.ecs.register::<$Type>();
|
||||
)*
|
||||
@ -195,7 +195,7 @@ fn main() -> rltk::BError {
|
||||
let mut gs = State { ecs: World::new() };
|
||||
|
||||
register!(
|
||||
gs,
|
||||
gs <-
|
||||
Position,
|
||||
Renderable,
|
||||
Player,
|
||||
|
Loading…
Reference in New Issue
Block a user