Skip to content

delaneyj/geck

Repository files navigation

G.E.C.K

Golang Entity Component Kit

Taking the relational archetype ideas from flecs and port them to Go.

What's different from alternatives like Arche

  1. Pros
    1. Generates custom API based on config file, your API is bespoke to your application and making more like a DSL.
    2. Uses sparse sets with groups allowing perfect SOA data layout.
    3. Initial benchmarks show its faster to add and remove components and event query.
    4. Handles relationships with any number of components.
    5. Has seperate API generated for tags vs components.
    6. Has custom API for components with only a single field to optimize out function calls.
  2. Cons
    1. Code generation is required. But as soon as you generics I think you are tied to recompiling your code anyway.
    2. Have to write a config file. 1

It uses Go's generics however there are no good way to make clean API with the current interface constraints. For example having a slice of different SparseSet[T] has to be done with any, whereas with code gen we can be more explicit.

This is a work in progress, and the API is subject to change.

1 Actively working on a Web based real-time config generator built into the generator.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published