Questions tagged [entity-component-system]

Used when referring to the Entity-Component-System (ECS) architecture.

Filter by
Sorted by
Tagged with
1
vote
0answers
35 views

Entity Component System: Dependency Between Systems

Inspired by the Entity Component System Architecture, I started to refactor my 2D tiled-based game to follow the rule "favor composition over inheritance". However, after writing the ...
0
votes
0answers
17 views

ECS: Should Systems access only one component-type [duplicate]

Let's say I have a Transform-component-type, and a Color-component-type (to keep things simple). I also have an entity E that is ...
2
votes
1answer
53 views

Component instance reference in Unreal Engine 4

I'm creating a C++ script and I want to get a reference to a component instance. For example, imagine that I want to get the player camera, which is a ...
0
votes
0answers
23 views

Managing player/AI state in Entity Component System

I am working on a 2d platformer game. Right now, I'm also using ECS. My question is how can I manage player's and AI current states in the context of ECS when some states are exclusive and some may be ...
0
votes
1answer
59 views

Entity component system: how and where store pointers to system resources or third-party lib's objects?

I'm migrating my game pet-project to ECS. I use C# (custom-made engine, not Unity). It goes pretty well, but one big thing is making me worry. This is how and where to store pointers to system ...
0
votes
0answers
87 views

Roguelike movement system

I'm trying to implement a roguelike movement system for my game. I'm using the ECS architecture. The requirements are: entities will have a mass, on which should slow down the entity movement ...
0
votes
1answer
70 views

ECS: Movement system

I'm a game developer enthusiast. I've decided to implement a game, however I'm pretty confused about all the movement mechanics (kinematics). Here goes a couple questions: Velocity x acceleration x ...
2
votes
0answers
85 views

Efficient communication between entities using ECS via entt

To avoid confusion about the ECS terms I'll use, I explain them here quickly. I use entt terminology and set-up my architecture like this: Entity: is only an id (...
1
vote
1answer
66 views

Is it useful to distinguish between two different kinds of events?

i have thought about this for a long time and i think i just going in circles. I need someone to tell me if im just simply overthinking it. So, first of all im coming from a 'classical' ECS approach: ...
0
votes
0answers
33 views

Should the HUD be Entites in a ECS ? And how to handle Events if so?

I'm building a GameEngine using Ashley and some how I can't figure out how. I through I could use something like this. Or use the Signal/Listener from Ashley. But how to Implement a interactive HUD?...
1
vote
2answers
108 views

ECS - Lantern implementation / How does the RenderSystem determine which one to choose? Entity-Datastructure

I want to implement ECS in my game. The more I read the more insecure I get. The current available Components for a Entity processed by the RenderSystem are: RenderComponent (mesh, texture, ...
0
votes
1answer
63 views

Handling input from an ECS input system into actions in another system/actions on a entity?

Some background on my engine, each system stores a reference to an entity which has the relevant components for that system. For example movement system has only entities which possess position ...
0
votes
1answer
58 views

How do you handle entity life-time and entities without all components in an ECS?

I'm just starting to implement my own ECS and am drawing everything down on paper to make sure I understand it all before tackling the implementation in code. However I'm getting stuck on entity-...
0
votes
2answers
99 views

How does ECS handle systems which need to know more about the environment of the entities it processes?

I'm trying to wrap my head around the concept of ECS (Entity Component System). I think I grasp the concept of the different parts, Entities, Components, and Systems. Entities: Basically just a ...
0
votes
1answer
42 views

How to do you separate or do you separate a Player/Non Player movement, action, behavior states in one or more component?

Assume we are using Finite State Machine, what is the best way to organize states? Given I have current StateComponent, all states are here. ...
0
votes
0answers
28 views

Return different components by name in entity component system

I'm working on an entity component system but I'm having trouble with the editor. Components take the form of structs with this formula Component healthComponent; This works fine when you know what ...
1
vote
1answer
273 views

Using EntityManager from inside a system

I am using Entities v0.8 I am trying to build a Spawner, and this is the system ...
1
vote
1answer
151 views

ECS as part of the rendering pipeline of an engine

I'm trying to integrate ECS design into my game engine. Currently I'm trying to mimic the components of unity (although not pure ECS) with MeshFilter (holds ...
0
votes
0answers
113 views

Scale / NonUniformScale is not applied to entity

I'm just learning the new Unity ecs and trying to change the size (scale) of an entity. Everything works fine, I can change the rotation, the position but not the scale. I'm wondering why. I did ...
3
votes
0answers
297 views

Is ECS an object-oriented design in disguise? (rather philosophical/technical)

Correct me if I'm wrong, but having read a lot about the ECS-Pattern in general and in the context of current game engines I am beginning to wonder if the ECS-Pattern in it's core is hardly more than ...
0
votes
0answers
100 views

Unity ECS burst compiler error “Cannot find the field TypeInfos”

I'm getting this weird error messages whenever I start my game. I can't find out why I get this message below. Library\PackageCache\com.unity.entities@0.5.1-preview.11\Unity.Entities\Types\...
0
votes
1answer
1k views

How to make animation in unity Dots hybrid?

I'm working on isometric game in 2D but didn't find any good tutorial in how to handle animation...any help?
1
vote
0answers
78 views

How do set a layer on an ECS entity?

I'm using Unity ECS entities to draw out some tiles. I would like to determine the layer (or sortOrder) of the rendered tile so that if a tile is placed over another at the same position, the tile ...
1
vote
0answers
160 views

How to sync entities in an ECS game?

I'm wondering how to engineer a client server sync of entities in a multiplayer game which is using an ECS. When the server changes some values of the components of an entity, I thought the best ...
5
votes
3answers
1k views

What is a pure ECS?

What is a "pure" ECS? What makes an ECS pure or not? Although the term appears to have come up since as early as 2013 in this community, it appears that often, a user asking a question feels the need ...
0
votes
0answers
41 views

Entity Component System. System and managed / filtered entities storage

Recently, I have been working on my own implementation of an ECS. One of the decisions I made was to make systems store a contiguous vector with all the entities that the system would work on (for ...
1
vote
0answers
46 views

How to find and modify specific entity or gameobject in Hybrid ECS?

I am rotating 3 cubes in Unity with Hybrid ECS and the code goes like this : ...
2
votes
1answer
312 views

Tilemap collision in Pure ECS?

I'm currently making a 2D topdown dungeon crawler using pure ECS and Data Oriented Design. So I only use structs of arrays for all my components. I have now added tilemap generation, but was wondering ...
0
votes
0answers
36 views

How to execute something on a main thread in ECS?

I have a game in which I have 5000 spheres on the scene simultanously. I needed the spheres to check for collisions with player's mouse, so it looks like the player is removing the balls with his ...
0
votes
1answer
90 views

Hidden copies of the environment in an entity component system

For reasons outside the scope of this question, my game has several full copies of the game environment running asynchronously. At any one time, only one of these is rendered. This is trivial to ...
3
votes
2answers
204 views

How do I build the dependency graph on ECS?

ECS is excellent at decoupling: you split your game logic into multiple pieces, and every system is responsible for dealing with a specific piece. However, I don't know if each system should be aware ...
1
vote
1answer
79 views

Should fields in components in an ECS use polymorphism?

I've just started to try and learn how to use ECS (Entity component systems), but I'm having trouble understanding the concepts behind components. Should adding more types of components, or trying to ...
1
vote
1answer
950 views

IConvertGameObjectToEntity interface on Unity ECS

Was working on ECS and following the tutorials by Mike Geig in Unite Copenhagen on YouTube(https://youtu.be/BNMrevfB6Q0), and understood that unity automatically converts transforms, mesh renderers ...
1
vote
2answers
2k views

Unity conversion of Gameobjects to ECS

I have not worked with ECS before, so I was following the tutorial by Unity's Mike Geig on Youtube to convert gameObjects to ECS from Unite Copenhagen, and this code does nothing, and there are no ...
5
votes
1answer
426 views

How can I create a templated function to add components to their necessary containers using an ECS system?

I had implemented a basic ECS system and was then informed that it should be changed as each system should not directly store their required components. I have created a ...
1
vote
1answer
109 views

Where should I put units and items in a squad-combat ECS-based game?

So I'm working on a game where squads of varied units would explore, fight, trade and build on an overworld map. Combat would be automated more or less, and happen on the overworld. Basically, ...
2
votes
0answers
68 views

Properway to pass information from one system to another in an entity component system design

After having read some example programs (namely Pong, Snake and Pacman) I am now experiencing with ECS. I am wondering where to put the elements for a reward flow. Do you know good practices for ...
0
votes
1answer
49 views

Reading and writing components from multiple systems in ECS [duplicate]

As a learning exercise, I'm building my own ECS. I've got a situation where two separate systems want to query and possibly update a Transform component - input ...
5
votes
2answers
788 views

Entity Component System: where do I put containers?

I'm pretty new when it comes to the whole Entity Component System structure and I got some questions I just can't wrap my head around. I know that for example collisions, you'd have a ...
3
votes
1answer
855 views

Dealing with more complex entities in an ECS architecture

Preamble: I'm working on a level editor for my engine, which uses an ECS architecture. I have around a dozen component types so far, mostly dealing with graphics, like lighting components, model, and ...
0
votes
1answer
108 views

How to handle dynamic hierarchical entities in ECS

Here's the analogy: I have an organism which is composed of cells which can be further composed of a medley of attachments. What I have currently is a sort of event chain between child/parents to ...
4
votes
2answers
2k views

Fastest way to look up an entity with a set of components?

I'm currently trying to implement an ECS system, but I've sort of ran into a problem trying to fetch all of my entities that have a specific set of components. I currently have a Dictionary that maps ...
0
votes
1answer
169 views

Intellisence doesn't show the ECS API Summaries

I am not sure if this is more of an ECS topic problem or packages in general. but it would be really helpful for ECS programming with all the summaries the Unity has provided. For unity engine methods,...
0
votes
0answers
668 views

Unity “Convert To Entity” does not work (Render) with “Skinned Mesh Renderer” for Animations

I'm trying to make a game with Unity's ECS and Job System. I came across the issue where, Convert To Entity does not support Skinned Mesh Renderer. It does not render the mesh. I need it for ...
0
votes
2answers
461 views
3
votes
1answer
4k views

How could I implement an ECS in C? [closed]

I'm looking into how to do a game engine using only C and wanted to know how to implement ECS in C. I didn't find any ECS implementation for C, it only seems to exist for C++. So I'm wondering... Is ...
0
votes
2answers
485 views

How to design components for tile-based movement in an RPG using ECS

I'm trying to re-write a small game of mine using ECS mostly for educational purposes and to see if it fits top-down RPG games in the style of Pokemon (gameboy). Since everything is tile based, ...
3
votes
1answer
991 views

Handling input in a custom ECS engine

I've been implementing an Entity Component System into my custom toy engine so I can learn more about it. Currently I have the following problem: I can't think of a way of implementing input as a ...
1
vote
2answers
424 views

How do the systems find the entities they should operate on in Entity-Component-System pattern?

I have read many articles about ECS patterns. Many of them are clear on what the entity and components are but don't really talk about the system because it "varies" or just use plain English to ...
1
vote
2answers
683 views

How can I handle scripting-like tasks in my ECS?

So I have been getting more and more into ECS architecture, and I am having a bit of trouble wrapping my head around how to handle custom actions/callbacks. For instance, let’s say I want to have a ...