more ecs
This commit is contained in:
+13
-1
@@ -1,6 +1,18 @@
|
||||
package shoal
|
||||
|
||||
Entity :: struct {
|
||||
id: i32,
|
||||
id: int,
|
||||
components: [dynamic]struct{},
|
||||
}
|
||||
|
||||
spawn_entity :: proc(app: ^App) -> Entity {
|
||||
entity: Entity
|
||||
entity_len := len(&app.entities)
|
||||
entity.id = entity_len
|
||||
|
||||
return entity
|
||||
}
|
||||
|
||||
add_collection :: proc(app: ^App, component: $T) {
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user