alias CptList = List[ComponentList]
struct Entity:
var components: CptList
fn __init__(inout self, components: CptList):
self.components = components
fn update(inout self):
for i in range(self.components.__len__()):
self.components[i].update()
fn addCpt(inout self, value: ComponentList):
self.components.append(value)
alias CptList = List[ComponentList]
struct Entity:
var components: CptList
fn __init__(inout self, components: CptList):
self.components = components
fn update(inout self):
for i in range(self.components.__len__()):
self.components[i].update()
fn addCpt(inout self, value: ComponentList):
self.components.append(value)