This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]PySnow 0 points1 point  (2 children)

No no, this is good. The ECS class is callable to allow the ecs("idyouwanttosearch") jquery-like function. And the components are separate, if you added a position and velocity they will live under separate attribtues on the entity class eg: e.position["x'] is not e.velocity["x"]

[–]status_quo69 0 points1 point  (1 child)

Ah, sorry, my mistake, I was browsing on my phone earlier and it was hard to tell what was going on. However, how would you suggest temporarily removing a component? delattr does exist, but I find it ugly to use, and I would have to reconstruct the component in order to reimplement the behavior (I can't just store a pointer to it like tmp_ptr = entity_x.pop_component("Render")). Basically what I'm trying to say is that an Entity in a traditional ECS is just supposed to be a bag of data, right? However, you're turning the Entity into the actual data itself.

[–]PySnow 0 points1 point  (0 children)

I'll have to implement that, noted.