All Questions
Tagged with entity-component-system game-development
11 questions
0
votes
0
answers
57
views
How can I pass a generic function to a class in C#
I'm currently working on a Entity Component System (ECS) for a game I'm developing in C# and Monogame.
My GameObject class has a dictionary with all its components, and this method is written to ...
0
votes
2
answers
110
views
How to iterate over different structs in C++ using a single function
I'm developing an Entity Component System (ECS) in C++ and I'm trying to find an efficient way to iterate over different component structs using a single function. Here's an example of my component ...
1
vote
1
answer
100
views
Function pointers vs polymorphism in a game engine ECS architecture [closed]
So I have a question about ECS and how to structure it in a way that's performant in C++. Say I want to have components that are just data, and systems that are just logic, and I want to execute all ...
0
votes
0
answers
20
views
How to cast a unique_ptr of base class to template derived class?
I have a base class for components and a derived class for my ECS arch. I need to store different types of values so my derived class is a template class.
Base class & template derived class :
...
0
votes
0
answers
320
views
How do I make a connection between an entity and a component in an ECS?
Recently I started learning about ECS and I decided to try and create a very basic implementation on my own. I made myself an enum with the component names and two basic components:
enum Components {
...
2
votes
0
answers
182
views
How can I have multiple forces act on an entity in Bevy?
I'm making a game in rust, in Bevy with Rapier2d physics. I want to apply forces to the entities from different functions (systems).
How is multiple external forces added to entities?
4
votes
0
answers
2k
views
EnTT: Creating new component-types at runtime, or "tagging" a subgroup of entities?
I'm working in a group project on a small 2D minecraft-like game, applying the Entity Component System design pattern. We're required to use the EnTT framework.
We'd like to make it easier to manage ...
1
vote
1
answer
891
views
Dynamically-typed entity component system in Rust
The Problem
I am building an entity component system for a game engine that I'm trying to build, and I'm not quite sure how to proceed in a strict typed language, in this case, Rust.
I'd like the ...
5
votes
1
answer
3k
views
Questions about Pure ECS (Entity Component System) and update systems
I have written an ECS but I have some questions about the update phase. (in systems)
I have read many articles, but not found references to this sort of problems.
In order to have benefits from ECS (...
0
votes
1
answer
186
views
How to get values in a struct-of-arrays (SOA) through a generic type?
I am looking for your feedback/advice on a piece of code.
Basically, I have a SOA like this one:
struct Entities {
pub meshes: FakeArena<Mesh>,
pub lights: FakeArena<Light>,
}
...
1
vote
1
answer
709
views
Animate Player using Finite State Machine in Ashley ECS
I have a big school project and I'm developing a Pixel Platformer game using libGDX.
I'm using ECS for the most part, but I've been having trouble rendering my player's animations because I can not ...